feat(tmux): add second prefix for nested in ssh
This commit is contained in:
parent
62ccbf5d4b
commit
a1b422e29e
|
@ -3,7 +3,7 @@
|
||||||
if [[ $# -eq 1 ]]; then
|
if [[ $# -eq 1 ]]; then
|
||||||
selected=$1
|
selected=$1
|
||||||
else
|
else
|
||||||
selected=$(grep "Host .*" ~/.ssh/config | grep -v "*" | sed "s/Host \(.*\)/\1/" | fzf --cycle --bind 'tab:toggle-up,btab:toggle-down')
|
selected="$(grep 'Host .*' ~/.ssh/config | grep -v '*' | sed 's/Host \(.*\)/\1/' | fzf --cycle --bind 'tab:toggle-up,btab:toggle-down')"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -z $selected ]]; then
|
if [[ -z $selected ]]; then
|
||||||
|
|
|
@ -5,9 +5,7 @@ set -s escape-time 0
|
||||||
|
|
||||||
set-option -g focus-events on
|
set-option -g focus-events on
|
||||||
|
|
||||||
unbind C-b
|
set-option -g prefix2 C-s
|
||||||
set-option -g prefix C-s
|
|
||||||
bind-key C-s send-prefix
|
|
||||||
|
|
||||||
bind r source-file "$XDG_CONFIG_HOME/tmux/tmux.conf"
|
bind r source-file "$XDG_CONFIG_HOME/tmux/tmux.conf"
|
||||||
set -g base-index 1
|
set -g base-index 1
|
||||||
|
@ -28,15 +26,15 @@ if-shell -b '[ "$(uname -s)" = "Darwin" ]' {
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim-like pane switching
|
# vim-like pane switching
|
||||||
bind -r ^ last-window
|
bind ^ last-window
|
||||||
bind -r k select-pane -U
|
bind k select-pane -U
|
||||||
bind -r j select-pane -D
|
bind j select-pane -D
|
||||||
bind -r h select-pane -L
|
bind h select-pane -L
|
||||||
bind -r l select-pane -R
|
bind l select-pane -R
|
||||||
|
|
||||||
bind-key -r f run-shell "tmux neww ~/.config/tmux/tmux-sessionizer"
|
bind-key f run-shell "tmux neww ~/.config/tmux/tmux-sessionizer"
|
||||||
bind-key -r F run-shell "tmux neww ~/.config/tmux/tmux-ssher"
|
bind-key F run-shell "tmux neww ~/.config/tmux/tmux-ssher"
|
||||||
bind-key -r T run-shell "tmux neww ~/.config/tmux/tmux-sessionizer ~/temp"
|
bind-key T run-shell "tmux neww ~/.config/tmux/tmux-sessionizer ~/temp"
|
||||||
bind-key -r R run-shell "tmux neww ~/.config/tmux/tmux-sessionizer ~"
|
bind-key R run-shell "tmux neww ~/.config/tmux/tmux-sessionizer ~"
|
||||||
bind-key -r G run-shell "tmux neww ~/.config/tmux/tmux-ggclone"
|
bind-key G run-shell "tmux neww ~/.config/tmux/tmux-ggclone"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue