dotfiles/.config/tmux/keybinds.conf
2024-08-20 02:20:14 +03:00

29 lines
823 B
Text

# Change prefix key to C-a, found in in GNU Screen
unbind-key C-b
set-option -g prefix C-a
bind-key C-a send-prefix
# moving
bind u previous-window
bind i next-window
bind n "new-window -c '#{pane_current_path}'"
# splits
bind h "split-window -hb -c '#{pane_current_path}'"
bind j "split-window -v -c '#{pane_current_path}'"
bind k "split-window -v -b -c '#{pane_current_path}'"
bind l "split-window -h -c '#{pane_current_path}'"
# Rebind command key to ;
bind ';' "command-prompt"
# Reload config on C-r
bind C-r "source-file ~/.config/tmux/tmux.conf"
# session binds
bind C-n "new-session -c '#{pane_current_path}' -s '#{b:pane_current_path}'"
bind C-x "set-option -g detach-on-destroy on; kill-session"
bind X "set-option -g detach-on-destroy off; kill-session; set-option -g detach-on-destroy on"
# vim: ft=tmux