Right now, the name of my frontmost window in Terminal.app is "pudge@slashdot-nfs-1:/usr/local/src — ssh". How does Terminal.app know I am logged into that machine, and am in that directory? I do know "pudge@slashdot-nfs-1:/usr/local/src" is called the "custom title" portion of the name, but I do not know how it is being set automatically.
Re:Play with this:
pudge on 2003-11-19T06:45:57
Aha! It was doing:Neat little trick. Thanks, that rules.PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME%%.*}:${PWD/#$HOME/user/}\007"'
Re:Play with this:
blech on 2003-11-19T12:56:17
Yes, the Terminal in Panther uses xterm title escapes. I noticed it a few weeks ago while a friend was logged into a work machine (which all have the appropriate trickery in a bash config file somewhere), and was wondering how long it would take for folks to notice it.
I'm not sure if you can override it using the Terminal window inspector to set a custom title, as I don't have Panther yet. I'd hope so. (Otherwise, I suppose you could edit the config files wherever you needed to, but that's a bit tedious.)
There is also an easy GUI way of changing the Terminal title bar.
Window Settings...
in the Terminal menu, it's right below Preferences
.Window
item in the menu at the top of the Terminal Inspector
window which appears.
I have it set to display the active process name, the window size (104x57 characters is half of my screen, and is a handy size for reading man pages), and the shortcut command key for that window. You can also enable the tty name, the