Created
February 11, 2019 15:30
-
-
Save wsgac/e31ff633ad4927e3d0afd822256b275c to your computer and use it in GitHub Desktop.
Override Tmux's window switcher to display pane numbers upon switch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Invoke our custom command when switching windows | |
bind -T prefix n run "tmux-switch-windows n" | |
bind -T prefix p run "tmux-switch-windows p" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# -*-sh-*- | |
# This file needs to be placed somewhere in $PATH for Tmux to see. | |
case $1 in | |
"p") tmux previous-window ;; | |
"n") tmux next-window ;; | |
esac | |
tmux display-panes |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment