Remove unneeded if loops
This commit is contained in:
parent
ab4841031d
commit
ce80b81516
1 changed files with 4 additions and 18 deletions
|
|
@ -1,22 +1,11 @@
|
||||||
# use vim copy/paste keybindings
|
# use vim copy/paste keybindings
|
||||||
setw -g mode-keys vi
|
setw -g mode-keys vi
|
||||||
|
|
||||||
# needs xclip for system clipboard
|
# Copy vim-style to clipboard
|
||||||
run-shell "tmux setenv -g TMUX_VERSION $(tmux -V | cut -c 6-)"
|
bind -t vi-copy y copy-pipe "xclip -sel clip -i"
|
||||||
if-shell -b '[ "$(echo "$TMUX_VERSION < 2.4" | bc)" = 1 ]' \
|
|
||||||
"bind-key Escape copy-mode; \
|
|
||||||
bind-key -t vi-copy Escape cancel; \
|
|
||||||
bind-key p paste-buffer; \
|
|
||||||
bind-key -t vi-copy v begin-selection; \
|
|
||||||
bind-key -t vi-copy V select-line; \
|
|
||||||
bind-key -t vi-copy r rectangle-toggle; \
|
|
||||||
bind -t vi-copy y copy-pipe 'xclip -in -selection clipboard'"
|
|
||||||
|
|
||||||
if-shell -b '[ "$(echo "$TMUX_VERSION >= 2.4" | bc)" = 1 ]' \
|
# Paste clipboard into window
|
||||||
"bind-key -T copy-mode-vi 'v' send -X begin-selection; \
|
bind C-v run "tmux set-buffer \"$(xclip -o -sel clipboard)\"; tmux paste-buffer"
|
||||||
bind-key -T copy-mode-vi 'V' send -X select-line; \
|
|
||||||
bind-key -T copy-mode-vi 'r' send -X rectangle-toggle; \
|
|
||||||
bind-key -T copy-mode-vi 'y' send -X copy-pipe-and-cancel 'xclip -in -selection clipboard'"
|
|
||||||
|
|
||||||
# split panes using | and -
|
# split panes using | and -
|
||||||
bind | split-window -h
|
bind | split-window -h
|
||||||
|
|
@ -54,6 +43,3 @@ setw -g window-status-format ' #I#[fg=colour0] #[fg=colour0]#W '
|
||||||
set -g history-limit 10000
|
set -g history-limit 10000
|
||||||
|
|
||||||
set -g mouse on
|
set -g mouse on
|
||||||
|
|
||||||
# terminal colors
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue