I want to have a function in
.bash_login that displays text if the current terminal is XTerm, but NOT Terminology. When I do
echo $TERM in Terminology, it outputs
xterm How can I tell them apart?
I don't know if this is the 'right' way to do it, but you could find what command the parent terminal was invoked with by calling
You can then test the value of the command string - for example using a case statement
Here is a another (simpler IMO) way of doing it. I don't have enlightenment, so I can't test it on Terminology, but I did test it with gnome-terminal, terminator and xterm.
Now in order to figure out your terminal's process name, open your terminal and run
This will print out the terminal's process name (providing you are running bash of course).
A fuller version that checks for several different terminal emulator's I have installed: