Last active
August 29, 2015 13:57
-
-
Save hallettj/9749276 to your computer and use it in GitHub Desktop.
tmux key bindings to run common git commands in a new split
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
# open vim in a new split | |
bind e split-window -h -c "#{pane_current_path}" sensible-editor | |
# shortcuts for common git operations | |
bind g split-window -h -c "#{pane_current_path}" 'GIT_PAGER="less -+F" git lg' | |
bind D split-window -h -c "#{pane_current_path}" 'GIT_PAGER="less -+F" git diff' | |
bind C split-window -h -c "#{pane_current_path}" 'GIT_PAGER="less -+F" git diff --cached' | |
bind A split-window -h -c "#{pane_current_path}" 'git add -p' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment