Fail rather then run xterm or provide a way to detect if a terminal is specified.
Created by: simotek
I've had a request to include this inside xdg-terminal
but I don't want to reimplement all the logic to detect if someone has actually specified a terminal which is probably the case on most systems at the moment. Also in a future case where a distro might automatically install xdg-terminal-exec
but leave it unconfigured xdg-terminal
currently has more sensible fallbacks then xterm for most users even if they are hard coded for Desktop Environments.
I guess there are two ways of handling this, one would be for xdg-terminal-exec
to have an optional flag that if passed exists with an error code if no terminal is found which could be tricky because xdg-terminal-exec maybe should pass back the result of the called process. The other would be to add a flag that doesn't execute anything but tells you which terminal would be used currently, which might be useful for other purposes anyway.