I'm labeling my Tmux tabs with the current file in vim like so:
autocmd BufEnter * let &titlestring = ' ' . expand("%:t")
set title
set t_ts=k
Then I have a VimLeave autocmd to have tmux rename the tab when I exit:
autocmd VimLeave * call system("tmux setw automatic-rename")
However, when I exit vim, the tab is renamed to "Thanks for flying Vim"
Any ideas how to fix this?
t_ts
option. If you find that this option is the wrong value in Vim, then you probably just set the wrongTERM
environment variable. This is probably why restoring the old title doesn't work.