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
|
||||
setw -g mode-keys vi
|
||||
|
||||
# needs xclip for system clipboard
|
||||
run-shell "tmux setenv -g TMUX_VERSION $(tmux -V | cut -c 6-)"
|
||||
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'"
|
||||
# Copy vim-style to clipboard
|
||||
bind -t vi-copy y copy-pipe "xclip -sel clip -i"
|
||||
|
||||
if-shell -b '[ "$(echo "$TMUX_VERSION >= 2.4" | bc)" = 1 ]' \
|
||||
"bind-key -T copy-mode-vi 'v' send -X begin-selection; \
|
||||
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'"
|
||||
# Paste clipboard into window
|
||||
bind C-v run "tmux set-buffer \"$(xclip -o -sel clipboard)\"; tmux paste-buffer"
|
||||
|
||||
# split panes using | and -
|
||||
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 mouse on
|
||||
|
||||
# terminal colors
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue