After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 576920 - title command line option order is significant
title command line option order is significant
Status: RESOLVED DUPLICATE of bug 311565
Product: gnome-terminal
Classification: Core
Component: general
2.24.x
Other Linux
: Normal minor
: ---
Assigned To: GNOME Terminal Maintainers
GNOME Terminal Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-03-27 00:51 UTC by Daevid Vincent
Modified: 2009-04-12 10:41 UTC
See Also:
GNOME target: ---
GNOME version: 2.23/2.24



Description Daevid Vincent 2009-03-27 00:51:44 UTC
gnome-terminal --title=foo --geometry=190x30 --window-with-profile=taillog --command 'ssh pse03 taillog.py'

will spawn a window of the right geometry. 
Then it will name that window "foo" 
promptly changed to "vincentd@psedev1: ~/Code"
then it spawns a second "default" sized terminal (ignoring my geometry I specified), using the "taillog" profile and runs the taillog.py script within it.

However, and this is the part that's amusing...

gnome-terminal --geometry=190x30 --window-with-profile=taillog --command 'ssh pse03 taillog.py' --title=foo

works exactly right (note that 'title' is now on the end, AFTER the --window... command I suspect is the key here)

LOL! get it! the order of the commands matters! HAHAH! 
(yet nowhere does the documentation mention this, nor is this even remotely expected behavior)

*rolls eyes*
Comment 1 Mariano Suárez-Alvarez 2009-03-27 19:03:34 UTC
The meaning of what you wrote depends critically on what you mean by "[it] works exactly right"...

Most command line options affect the "current window/tab" being described, except those that create new windows and tabs. 

Your first example starts with an implicit "create a window" command line argument, then tells the app to put a specific title on it (which *after* the window is shown is changed by the bash instance running in it: g-t cannot do much about this...), and of a specific geometry; the following --window-with-profile tells g-t that a new window follows, and the only thing being told to it is that is should be running a certain command (but you did not day anything about what geometry or title you want on this second window)

In conclusion: the order of the command line arguments does matter, and it is expected that it does. Maybe the docs should be more emphatic about it, I guess...
Comment 2 Christian Persch 2009-04-12 10:41:52 UTC
Command line option order matters, yes. --help-all also clearly explains this in g-t 2.26.0 . Bug 311565 is about adding a manpage which would explain this in detail; marking as dup.

*** This bug has been marked as a duplicate of 311565 ***