[Konsole-devel] [Bug 126702] New: Need "execute command in new tab" command-line option and DCOP interface

Tristan Miller psychonaut at nothingisreal.com
Thu May 4 03:51:48 UTC 2006


------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=126702         
           Summary: Need "execute command in new tab" command-line option
                    and DCOP interface
           Product: konsole
           Version: unspecified
          Platform: SuSE RPMs
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: wishlist
          Priority: NOR
         Component: general
        AssignedTo: konsole-devel kde org
        ReportedBy: psychonaut nothingisreal com


Version:            (using KDE KDE 3.5.2)
Installed from:    SuSE RPMs

I often need to open multiple konsole tabs, each running the same program but with different arguments.  Unfortunately, there seems to be no way to do this automatically -- not even via DCOP.  What I would like is for konsole to support a command-line option similar to -e, except that instead of running the command in a new konsole window, the command is run in a new tab of an existing konsole window.  This feature is analogous to Mozilla's "-remote openURL(URL,newtab)" command-line option.

For example, the following command, when run from an existing konsole shell, would open three more tabs in the same konsole window:

[psy polecat:~]$ for f in a.html b.html c.html;do konsole --newtab lynx $f; done

Things are trickier if more than one konsole instance is currently running and you want the command to be run in a particular window.  You could either disallow this behaviour (i.e., --newtab can be run only from within konsole and applies only to the current instance), or add another command-line option which specifies which instance the new tabs should appear in.

Incidentally, a comment in Bug 13125 states that this can be done via DCOP, but it doesn't seem to be possible in Konsole 1.6.2.  The problem is that there seems to be no DCOP function for sending a command to a konsole session.  The aforementioned comment uses an interface named sendSession, but this interface does not exist:

[psy polecat:~]$ KONSOLE=`dcopstart konsole`
[psy polecat:~]$ echo $KONSOLE
konsole-24158
[psy polecat:~]$ LOCAL_SESSION=`dcop $KONSOLE konsole newSession`
[psy polecat:~]$ echo $LOCAL_SESSION
session-2
[psy polecat:~]$ dcop $KONSOLE $LOCAL_SESSION sendSession "echo foo"
no such function                                                                                  
[psy polecat:~]$ dcop $KONSOLE $LOCAL_SESSION
QCStringList interfaces()
QCStringList functions()
bool closeSession()
bool sendSignal(int signal)
void clearHistory()
void renameSession(QString name)
QString sessionName()
int sessionPID()
QString schema()
void setSchema(QString schema)
QString encoding()
void setEncoding(QString encoding)
QString keytab()
void setKeytab(QString keyboard)
QSize size()
void setSize(QSize size)
[psy polecat:~]$



More information about the konsole-devel mailing list