Skip to content

Instantly share code, notes, and snippets.

View silopolis's full-sized avatar

Jérémie Tarot silopolis

View GitHub Profile
@mislav
mislav / _readme.md
Last active April 1, 2026 07:38
tmux-vim integration to transparently switch between tmux panes and vim split windows

I use tmux splits (panes). Inside one of these panes there's a Vim process, and it has its own splits (windows).

In Vim I have key bindings C-h/j/k/l set to switch windows in the given direction. (Vim default mappings for windows switching are the same, but prefixed with C-W.) I'd like to use the same keystrokes for switching tmux panes.

An extra goal that I've solved with a dirty hack is to toggle between last active panes with C-\.

Here's how it should work: