0fb06e2824f13361bd661d1cb493c2af34c3792c
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

1) # C-b already in use by vim for page up. Use screen's prefix.
David Blume Remap tmux prefix key. C-b...

David Blume authored 4 years ago

2) set -g prefix C-a
3) unbind C-b
4) bind C-a send-prefix
David Blume Add C-a a in tmux; tweaks f...

David Blume authored 3 years ago

5) # Make ^a a send ^a (Useful in minicom)
dblume Restore ability to toggle b...

dblume authored 2 years ago

6) bind a send-prefix
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

7) 
8) # No delay for escape key press (vim mode changes)
9) set -sg escape-time 0
10) 
dblume Remap v and y for tmux copy...

dblume authored 2 years ago

11) # Copy mode more intuitive for vim users, use v and y
12) # From https://dev.to/iggredible/the-easy-way-to-copy-text-in-tmux-319g
13) # See https://ianthehenry.com/posts/how-to-configure-tmux/ for copy-pipe tips.
14) bind -T copy-mode-vi v send -X begin-selection
dblume tmux rectangle-toggle shoul...

dblume authored 2 years ago

15) bind -T copy-mode-vi C-v send -X rectangle-toggle
dblume Restore ability to toggle b...

dblume authored 2 years ago

16) bind -T copy-mode-vi y send -X copy-selection-and-cancel
dblume Remap v and y for tmux copy...

dblume authored 2 years ago

17) 
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

18) # Vim style pane splitting
dblume Restore ability to toggle b...

dblume authored 2 years ago

19) bind v split-window -h
20) bind s split-window -v
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

21) 
22) # Vim style pane selection
23) bind h select-pane -L
David Blume Delete some trailing whites...

David Blume authored 4 years ago

24) bind j select-pane -D
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

25) bind k select-pane -U
26) bind l select-pane -R
27) 
dblume Add pane resizing shortcuts...

dblume authored 2 years ago

28) # pane sizing with capital letters
29) bind -r H resize-pane -L
30) bind -r J resize-pane -D
31) bind -r K resize-pane -U
32) bind -r L resize-pane -R
33) 
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

34) # Use Alt-vim keys without prefix key to switch panes
35) bind -n M-h select-pane -L
David Blume Delete some trailing whites...

David Blume authored 4 years ago

36) bind -n M-j select-pane -D
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

37) bind -n M-k select-pane -U
38) bind -n M-l select-pane -R
39) 
40) # Use Alt-arrow keys without prefix key to switch panes
41) bind -n M-Left select-pane -L
42) bind -n M-Right select-pane -R
43) bind -n M-Up select-pane -U
44) bind -n M-Down select-pane -D
45) 
dblume Add tmux window shortkuts

dblume authored 11 months ago

46) # Use prefix-! to break-pane a pane into a new window.
47) # Use these to join another pane to this window (choosing which pane).
48) bind-key S choose-window 'join-pane -v -s "%%"'
49) bind-key V choose-window 'join-pane -h -s "%%"'
50) 
dblume tmux Tab to toggle full scr...

dblume authored 1 year ago

51) # Use Tab to rotate full-screen panes like I do vim buffers
52) bind -r Tab select-pane -t .+1 \; resize-pane -Z
53) 
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

54) # Theme
David Blume Add support for tmux; use p...

David Blume authored 4 years ago

55) set -g status-keys vi
56) set -g status-fg white
dblume Improve focus-based switchi...

dblume authored 7 months ago

57) set -g focus-events on
David Blume Add support for tmux; use p...

David Blume authored 4 years ago

58) set -g status-bg colour235
David Blume tmux status line pane refin...

David Blume authored 3 years ago

59) set -g status-left-length 10
dblume Tighten status line with tm...

dblume authored 2 years ago

60) set -g status-left "#[fg=green]#{?#{!=:#{window_panes},1},pane #P/#{window_panes},}#[default]"
David Blume Add support for tmux; use p...

David Blume authored 4 years ago

61) set -g status-justify centre
62) set -g status-right '#[fg=green]%m/%d %H:%M#[default]'
David Blume Added vim style scrolling.

David Blume authored 4 years ago

63) setw -g mode-keys vi
David Blume Premature optimization: tur...

David Blume authored 4 years ago

64) setw -g automatic-rename off
David Blume By default tmux sessions co...

David Blume authored 3 years ago

65) setw -g aggressive-resize
dblume Turn off allow-rename, dupl...

dblume authored 2 years ago

66) #set -g allow-rename on  ## ssh'ed servers may rename window to PS1, duplicating path
David Blume Want the pane's path to be...

David Blume authored 4 years ago

67) #setw -g window-status-current-format '#[fg=yellow]#I:#F:#T:.../#{b:pane_current_path}#[default]'
dblume Tighten status line with tm...

dblume authored 2 years ago

68) setw -g window-status-current-format '#{?#{!=:#{session_windows},1},#I:#W:,}#[fg=yellow]#{?window_zoomed_flag,Z:,}#{s\/home/dblume\~\:pane_current_path}#[default]'
dblume Better status for tmux wind...

dblume authored 2 years ago

69) setw -g window-status-format '#[fg=colour241]#I:#W#[default]'
David Blume Added vim mappings to tmux.

David Blume authored 4 years ago

70) 
dblume Enable neovim's italic high...

dblume authored 7 months ago

71) # This allows neovim's hi htmlItalic (also used by markdown) to use italic font
dblume tmux $TERM "tmux-256color"...

dblume authored 6 months ago

72) set -g default-terminal "tmux-256color"
dblume Enable neovim's italic high...

dblume authored 7 months ago

73)