LoginSignup
4
4

More than 5 years have passed since last update.

Puttyのタイトルバーに表示する文字列を変更する

Last updated at Posted at 2014-09-04

Puttyを使って複数の仮想マシンにSSH接続していると、どれがどれだか分からなくなってきます(個人的に)

仮想マシン単位で分けるなら/etc/zshrcファイルに、
ユーザ単位で分けるなら~/.zshrcファイルに以下を記述します。

zshrc
# Puttyのタイトルバーに表示する文字列を変更する
printf "\033P\033]0;${タイトルバーに表示する文字列}\007\033\\"

変更を反映します。

input
source /etc/zshrc

or

source ~/.zshrc

色まで変えたらもっと分かりやすくなると思ったのですが、なぜかうまくいかなかったので今回はここまでです。

参考URL

http://blog.kjirou.net/p/343
http://7ujm.net/etc/esc.html


※追記:tmuxを立ち上げると反映されなくなるので、~/.tmux.confファイルに以下を記述します。

~/.tmux.conf
set-option -g set-titles on
4
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
4