1
$ gnome-terminal  --tab  --title="700"  --disable-factory  -e

Failed to parse arguments: Option "--disable-factory" is no longer supported in this version of gnome-terminal.

I am using GNOME 3.

  • What version of gnome-terminal do you have? Considered using another terminal emulator? Maybe xfce4-terminal? – muru Feb 3 '16 at 5:42
  • I do not understand why this was downvoted. This is a legitimate question. Ubuntu is for all, not only for Linux-Pros! Please do not discriminate people because they are not fluent in English or do not grok shell syntax. We are here to help them! – Tino Jun 17 '17 at 8:52
1

If you really need multiple instances of gnome-terminal process running (but why should you?), follow the steps at https://wiki.gnome.org/Apps/Terminal/Debugging except for the gdb part.

| improve this answer | |
  • i can't understand what will i replace the sentence gnome-terminal --tab --title="700" --disable-factory with , will i write instead of it gnome-terminal-server --app-id my.foo.Terminal? – Ahmed Zain El Dein Feb 3 '16 at 15:07
  • Here's my reason for running separate gnome-terminal processes - I don't limit myself to a single X screen in my X desktop. I have multiple independent X screens. gnome-terminal, apart from the helpful gdb hack you link, is no longer able to have a terminal on more than one screen at a time. – Troy Folger Jun 25 '18 at 22:43
1

For the benefit of the reader.

The problem

Option --disable-factory got removed in V3.8 of gnome-terminal and there is no way to archive this behavior the easy way. At least not a way, which can be explained to people, who are not fluent in shell syntax.

Hence the command line

gnome-terminal  --tab  --title="700" --disable-factory -e ...

fails with the error presented in the question.

Please excuse this very personal side note: I really do not understand, why this crucial option got removed. Even Microsoft introduced an option to run cmd, explorer or powershell the blocking way. Microsoft listens to their users. But Gnome does not. Instead of officially documenting the hidden option --disable-factory, Gnome suddenly removed it. If they continue this course, they will make Microsoft win on the long term. That is very very sad and extraordinary stupid. (Sorry for this rant, but it has to be be said.)

BTW: Ubuntu 16.04 restored --disable-factory using a wrapper which emulates this feature. (If you look at the complexity of this wrapper, my rant still applies even more than before.)

Variant 0

I call this 0, because both are not really proper solutions. A proper solution is shown in Variant 1.

Varriant 0a

A first thing, you can try, is to remove option --disable-server:

gnome-terminal --tab --title="700" -e ...

However this has following drawback:

This does no more wait until gnome-terminal finishes. If there is another gnome-terminal running, the command immediately comes back. Usually this is not what you want, because this is, why option --disable-factory was present in the first place.

Variant 0b

So removing this option is only feasible in the case, where you can make sure, that in all and every case, no other gnome-terminal is running, ever.

If this is not the case, but you are in a case, where another running gnome-terminal must not be supported, you can try following desparate fallback variant:

killall -9 gnome-terminal
gnome-terminal  --tab  --title="700" -e ...

But beware! This unconditionally kills all gnome-terminals which are still open. In a production environment this usually will cause greater harm then it helps. You have been warned!

Variant 1

If you do not need to run it in gnome-terminal and can run it in some other terminal emulator. @muru commented a good replacement.

xfce4-terminal understands nearly the same set of options as gnome-terminal (and adds some very handy other options which are missing in gnome-terminal for years). It also has a documented option, which does, what --disable-factory did for gnome-terminal. The option --tab works differently to gnome-terminal and thus must be removed, too, to get something working. The replacement is:

xfce4-terminal --title="700" --disable-server -e ...

Also you can add a --hold option, if you want to be able to see the full output of the command before the window is closed:

xfce4-terminal --hold --title="700" --disable-server -e ...

Please note that xfce4-terminal has a little race-condition, which unfortunately truncates the output, so --hold is not fully effective. Fixing this properly (such that you can use it copy'n'paste) is beyond the scope of the answer, however usually adding a little echo $? && read -t.1 to the script which is executed with (behind) -e can solve it 99% of the time.

In case you get the message, that xfce4-terminal is missing, then you have to install it first. It can be installed in parallel to gnome, even that it belongs to another desktop variant (Xfce):

sudo apt-get install xfce4-terminal

The only drawback is, that xfce4-terminal has another look than gnome-terminal, and follows some other

Variant 2..∞

There are endless other possible variants to fix that issue. Most of them are really complicated. Too complicated for normal people, those, who are not really into shells.

So I leave them away. My recommendation is:

As noted by @muru, try to use xfce4-terminal instead of gnome-terminal.

Note to those, who grok shells

All simple solutions are not really perfect, as they do not return the command's return value (gnome-terminal does not, too). Sadly. To fix that this is a completely different story.

| improve this answer | |
0

Variant 3.

https://unix.stackexchange.com/a/502498/303187 To avoid cross posting i'm just leaving the link, follow it and scroll down if you're lazy to read - there is an archive to place in /, it has all the files to create

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.