Bug 52932 - Konsole: open command in new shell
Summary: Konsole: open command in new shell
Status: RESOLVED FIXED
Alias: None
Product: konsole
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Debian testing Linux
: NOR wishlist
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-01-13 01:19 UTC by NetVicious
Modified: 2003-03-12 20:29 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description NetVicious 2003-01-13 01:19:32 UTC
Version:            (using KDE KDE 3.0.3KDE 1.2KDE 1.2)
Installed from:    Debian testing/unstable PackagesDebian testing/unstable PackagesDebian testing/unstable Packages
OS:          Linux

Add one option for open another shell in the same Konsole window but in other shell (another button on kconsole toolbar)

This could be useful for opening in a script a lot of shells with commands using only one konsole window.

It could also detect the number of actual shells on a konsole window and when this number it's > 10 (or other number) create another Konsole window instead of adding other shell to the same konsole window.
Comment 1 NetVicious 2003-01-13 01:44:05 UTC
I'm refering to a special command/parameter of konsole that could be added to a
bash script (for example)

konsole -r command_to_open_in_a_new_shell
Comment 2 Stephan Binner 2003-01-16 22:00:06 UTC
This should be already possible with a little script based on this fragment: 
 
dcop | grep konsole | 
 while read instance; 
   do if [ `dcop $instance default sessionCount` -lt 10 ]; then 
     newsession=`dcop $instance default newSession` 
     dcop $instance $newsession sendSession $* 
     exit; 
   fi 
 done 
 
Note 1) The "otherwise" case starting a new Konsole is missing. Too lazy. :-) 
Note 2) Works only for Konsole instances started with "--script" parameter. 
Comment 3 NetVicious 2003-01-17 01:03:59 UTC
Ok, thanks for answer, I'm testing it now with Konsole 1.0.2 on KDE 2.2.2 and
the --script parameter doesn't exist. I think it was added on KDE 3.x version of
Konsole. isn't it?

Reading the code I see one $* that will be the command and parameters to run it ;-)

On KDE 2.2.2 dcop doesn't shows any line with konsole (now i have some konsole
instances on my kde). I think it will be due to KDE2 or the missing --script
parameter of my Konsole version.

If it's so easy why not add it to official Konsole ?
Comment 4 Stephan Binner 2003-01-18 11:18:34 UTC
Konsole/KDE 2.2 doesn't have this dcop functions. 
It's part of official Konsole (KDE 3.0.x), you just use an outdated version. 
Comment 5 NetVicious 2003-01-18 14:11:40 UTC
Ok, thanks for answer

I will wait for official Debian KDE3 packages
Comment 6 Stephan Binner 2003-03-12 20:29:13 UTC
*** Bug has been marked as fixed ***.