What is the maximum length of command line arguments in gnome-terminal?
... and is there a system environment variable which reports this value?
What is the maximum length of command line arguments in gnome-terminal?
... and is there a system environment variable which reports this value?
xargs
knows. On my system,The answer comes from the sysconf value
ARG_MAX
. To examine it on your system:For me, this reports
2097152
. For more details check the manpage:To get this inside a program, for example:
I don't really know about gnome-terminal, but the shell has not a 'fixed' limit, but the limit of the stack.
However there is an hardcode limit per-argument that is 128KB, that should not be a problem if you don't use 'very very very long arguments....'.
You can read more about this here:
http://www.mail-archive.com/[email protected]/msg05522.html