2
Within a gnome-terminal tab, I can invoke the "New Terminal in New Tab" command shift+ctrl+t
and it will add a tab to the current gnome-terminal window.
How can this be done programmatically?
I've tried various solutions mentioned here without success.
For example, exec gnome-terminal --tab --tab
replaces the current tab with a new window with two tabs. (By the way, 'man gnome-terminal' makes no mention whatsoever of the --tab option!)
--tab-with-profile=PROFILE
does the same thing, assuming one can identify the PROFILE in use, which is apparently not an easy thing to do (also, if the only profile defined is 'Default', as displayed by Edit: Preferences: Profiles, tab-with-profile does not recognise 'Default'!).