I’m just using the Cosmic Terminal that’s part of the Pop!_OS Cosmic Alpha, but I ran into similar issues with Gnome terminal and even with Termius.
Scenario: I’m currently working on leveraging a VPS to act as the gateway to my homelab so I have one ssh session to Unraid server and one to VPS. One in each tab. Obviously the name shows up as what the username@servername is called in each tab. But I keep getting tripped up and sometimes try to do something from the wrong machine. Once I even failed to realize that the ssh session to one of them cut out and I was back on my desktop and took me an embarrassingly long time to realize why stuff was failing.
So what are y’all using to keep that organized in your work flow? Separate terminal windows instead of tabs? Some shell customizations to make them look different than one another? Or just so ingrained in your brain that you never have this problem?
I (manually) set the background color of my terminals depending on the machine I connect to. I currently have profiles for red, green, blue, and black backgrounds with black as my default. I usually use red for ones I want to be especially careful of.
That’s a great idea. Do you have it persist between sessions? Like one server #1 it’s always green?
I just right click on the terminal to change the profile to whatever I feel like it should be in the moment (usually red). I do it by reflex, basically. I never felt the need to try to set up automation for different servers, but I expect there’s probably a way to do that if you really wanted to.