9

Everyday I launch a bunch of urxvtc -e tmux.

I am trying to find a way to override urxvt X window title ("tmux") with the current tmux session name set via :rename-session session_name.

Does any of you guys achieved that ??

Thanks !

Bathz
  • 415
  • 3
  • 12

1 Answers1

13

Try adding the following to your ~/.tmux.conf file.

# Turn on window titles
set -g set-titles on

# Set window title string
#  #H  Hostname of local host
#  #I  Current window index
#  #P  Current pane index
#  #S  Session name
#  #T  Current window title
#  #W  Current window name
#  #   A literal ‘#’
set -g set-titles-string '#S:#I.#P #W'

# Automatically set window title
setw -g automatic-rename
Jeremy W
  • 3,629
  • 20
  • 35
  • Hmm, it does not seem to be enough. It keeps displaying this boring "tmux". – Bathz May 31 '12 at 05:00
  • Ok, thanks having put me on the correct way. You first need to `set -g set-titles on`. Then you can customize the `set-titles-string` if you like. – Bathz May 31 '12 at 05:54
  • To be clear, if you include this to your answer I'll accept it, for posterity :). – Bathz May 31 '12 at 06:05
  • okay - I updated my answer and added some info on the character sequences – Jeremy W May 31 '12 at 14:21