Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a bind in vim for F5 key to trim whitespaces and I'm unable to use it in tmux. Instead of that letter "T" appears. Is there's any solution for that?

Actually it was working in putty, now I've switched to Xshell4.
Can this be TERM issue? inside tmux $TERM is screen

share|improve this question
up vote 3 down vote accepted

Does you .tmux.conf contain any lines that set default-terminal?

Assuming Xshell4 emulates xterm (check that $TERM is xterm within your shell outside of tmux...

Then try adding the following to your .tmux.conf

# xterm-style function key sequences
setw -g xterm-keys on

Also check what the term and ttytype variables are within Vim (inside tmux).

share|improve this answer
You mean $TERM? – Boris Ivanov Nov 21 '14 at 9:22
No. I mean term. In vim try :set term? – CraftyThumber Nov 21 '14 at 15:18

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.