creating/resizing/moving terminal panes and windows
executing long-running processes on servers over SSH, then coming back later
to see how they did
sharing a terminal sessions with remote team members while paired programming
And it can do all of this on just the home row. Very cool. Unfortunately, it’s a little tricky to get Tmux set up with Vim. Here’s how I
did it on OSX with iTerm.
Note: some of what follows presupposes that you have configured vim as I have.
For more details, check out my vim installation instructions in my dotfiles.
Installation
First the boring part:
Configuration
Now the fun part: customization!
You’ll want to create some tmux configuration files. You can view mine
here and
here.
To make things easy, I’ll paste the most important bits:
Don’t forget to source your tmux config files! From the terminal:
Finally, you’ll need to make sure iTerm’s color preferences are correct. Go to
iTerm > Preferences > Profiles > Terminal
and set Report Terminal Type to xterm-256color.
Otherwise vim’s color scheme will get messed up in tmux.
And, last but not least, here are some tmux commands that I found useful when getting started.
Thanks to …
thoughtbot for sharing their awesome vim and tmux configs!