LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Making rxvt-unicode change window title when using ssh (https://www.linuxquestions.org/questions/linux-software-2/making-rxvt-unicode-change-window-title-when-using-ssh-592015/)

tkarkkainen 10-15-2007 02:32 PM

Making rxvt-unicode change window title when using ssh
 
When I start rxvt-unicode (or urxvt) it has "user@local: ~" as the windows title. If I enter another directory, it changes to "user@local: ~/anotherdir". However, if I ssh to another machine from my home directory, it still says "user@local: ~" instead of "another_user@remote: ~". I'd prefer the latter since it would ease identifying the terminal windows. Is there anything I should try?

I'm using Kubuntu Feisty with rxvt-unicode 8.1.

tkarkkainen 10-15-2007 03:07 PM

Okay, consider this resolved. I was instructed in IRC to add the next line to ~/.bashrc on the remote machine:

Code:

PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"'
Works very well.


All times are GMT -5. The time now is 08:07 PM.