change the terminal title dynamically in X11
I was actually looking for this for quite sometime. Some years back in my bashrc was the proper setting for setting the terminal title when I did a cd, and I had completely forgotten how to do it. So today I searched quite a few commands the environment variables for doing the same and found it again.
Here it is (Just put this in your bashrc or bash_profile):
export PROMPT_COMMAND=’echo -ne ”\033]0;`pwd`”; echo -ne ”\007”’
[Edit] I just tried this with eterm and gnome-terminal and it works on both.
Related Articles:
- 2009/11/16 bash colors
- 2010/01/07 shell — one liner to selectively change case
- 2009/12/20 Know when you will type :q in your term instead of vi(m), the alias will chewed you out.
- 2009/12/18 Display a block of text with delineated by a start pattern and an end pattern
- 2009/12/07 View the newest xkcd comic.
Authored By Amit Agarwal
Amit Agarwal, Linux and Photography are my hobbies.Creative Commons Attribution 4.0 International License.