Closed jeremypw closed 3 years ago
Fixing this would faciliate a workaround in slingshot handling or applications or commands that need to be run in a terminal window by allowing the preferred terminal program to be identified correctly.
see https://github.com/elementary/applications-menu/issues/232
We shouldn't be changing this variable, it's more of an identifier of the capabilities of the terminal than it is the name of an executable to launch.
The code in GLib, via the linked issue, doesn't even check this environment variable, it's hardcoded to use xterm if none of the other hardcoded list of terminals are available.
It sounds to me that the correct solution to this problem is to submit a PR to GLib to add our terminal into the list, and put a workaround in applications menu itself to intercept launches of terminal applications and pass them to our terminal if it's installed, otherwise carry on doing what its doing now.
That code in GLib is a serious pain for everyone. @davidmhewitt Are we sure it will be accepted or does the elementary project get special treatment https://gitlab.gnome.org/GNOME/glib/-/issues/2324 ?
Perhaps there's discordance within the codebase itself :rofl: https://gitlab.gnome.org/GNOME/glib/-/commit/0b0fcfad11cadd43ff1ce96800ebbce70016ffc3
I don't know whether elementary terminal would be accepted into the list. But I know that changing the TERM environment variable isn't the solution, which is the part that's relevant to this discussion.
If the correct solution is not to change this repo then please close this issue.
Decided to test the waters with a reasonable pawn https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1946 and this confirmed that they don't want to accept that and want terminal maintainers to contribute https://gitlab.gnome.org/GNOME/glib/-/issues/338.
The environment variable
TERM
defaults toxterm
. It should be set toio.elementary.terminal
on initial install. (There should also be a way for the user to change/reset this but that is another issue).