]> Sergey Matveev's repositories - dotfiles.git/blob - tmux/.tmux.conf
Let's try command's output selector
[dotfiles.git] / tmux / .tmux.conf
1 set-option -g mode-keys vi
2 set-option -g base-index 1
3 set-option -g default-terminal "screen-256color"
4 set-option -g escape-time 1
5 set-option -g repeat-time 0
6 set-option -g history-limit 20000
7 set-option -g renumber-windows on
8 set-option -g terminal-features[0] "screen*:title:clipboard:ccolour:cstyle"
9 set-option -gU terminal-features[1]
10
11 set-option -g prefix C-a
12 unbind-key C-b
13 bind-key C-a send-prefix
14
15 bind-key -n C-PgUp previous-window
16 bind-key -n C-PgDn next-window
17 bind-key -n S-PgUp copy-mode -u
18
19 bind '"' split-window -c "#{pane_current_path}"
20 bind % split-window -h -c "#{pane_current_path}"
21 bind c new-window -c "#{pane_current_path}"
22 bind ] paste-buffer -p
23
24 set-option -g status-style "bg=black,fg=white"
25 set-option -g status-left "#S>"
26 set-option -g status-right "#T"
27 set-option -g status-justify centre
28
29 set-window-option -g automatic-rename on
30 set-window-option -g window-status-format "#I:#W:#T#F"
31 set-window-option -g window-status-style "bg=green fg=black"
32 set-window-option -g window-status-current-format "#I:#W#F"
33 set-window-option -g window-status-current-style "bg=red"
34 set-window-option -g window-status-last-style "bg=cyan"
35
36 bind-key b set-option status
37 unbind-key L
38
39 bind-key u {
40     capture-pane -J
41     save-buffer /tmp/tmux-buffer
42     delete-buffer
43     display-popup -E -w 100% "urlview /tmp/tmux-buffer"
44 }
45
46 bind-key y {
47     capture-pane -J
48     save-buffer /tmp/tmux-buffer
49     delete-buffer
50     split-window 'vim -c "set listchars=" -c "match ExtraWhitespace //" /tmp/tmux-buffer'
51 }
52
53 bind-key Y {
54     capture-pane -J -S - -E -
55     save-buffer /tmp/tmux-buffer
56     delete-buffer
57     split-window 'vim -c "set listchars=" -c "match ExtraWhitespace //" /tmp/tmux-buffer'
58 }
59
60 bind-key t display-menu \
61     music t "display-popup -E -w 100% '~/.tmux/bin/menu-music.sh'" \
62     pass p "display-popup -E '~/.tmux/bin/menu-pass-session.sh'" \
63     dict d "display-popup -E -h 100% '~/.tmux/bin/menu-dict.sh'" \
64     calc c "display-popup -E '~/.tmux/bin/menu-calc.sh'" \
65     cal l "display-popup 'cal -3N'" \
66     top o "display-popup -E -h 100% 'top -s 1'"
67
68 bind-key o display-menu \
69     find o "display-popup -E -w 100% \"~/.tmux/bin/fzf.zsh find '#{pane_current_path}'\"" \
70     procs p "display-popup -E -w 100% -h 100% \"~/.tmux/bin/fzf.zsh procs '#{pane_current_path}'\"" \
71     git-files g "display-popup -E -w 100% \"~/.tmux/bin/fzf.zsh git-files '#{pane_current_path}'\"" \
72     git-branches b "display-popup -E -w 100% \"~/.tmux/bin/fzf.zsh git-branches '#{pane_current_path}'\"" \
73     git-commits c "display-popup -E -w 100% \"~/.tmux/bin/fzf.zsh git-commits '#{pane_current_path}'\""
74
75 source-file ~/.tmux/rc/select-command-output