I have about a half dozen hosts that I ssh to on a regular basis. I often end up with multiple tabs, and it’s very helpful if the tab label indicates what machine I’m connected to. Using iTerm’s bookmarks, this works as desired with the bookmark name showing up as the tab name.
It took me a while, but I figured out a way to achieve the same result using the updated terminal program that ships with Leopard. With the new terminal it’s straight-forward to save connections that automatically ssh to the desired host, and also display the remote system’s name as the window title. Unfortunately, there’s no obvious way to override the tab label, which displays the shell name.
My solution is kind of crude, but it does work. Simply create a hard link to the ssh binary with the name of each remote system you need to connect to (symbolic links don’t work; ssh is still displayed). Then, while running terminal, copy one of the existing terminal templates and modify it as you normally would to change colors, etc. After that, in the shell settings tab, substitute the remote-name link you’ve previously created for “ssh.” An example makes this more clear:
instead of “ssh -l username remote-name” specify “remote-name -l username remote-name” and voila’, the remote system name is now displayed in the tab label.
Here’s the command to create the links as needed:
sudo ln /usr/bin/ssh /usr/bin/remote-name