-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtmux.conf
122 lines (102 loc) · 2.96 KB
/
tmux.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# ~/.tmux.conf
set-hook -g after-new-session "source-file ~/.tmux.conf"
bind r source-file ~/.tmux.conf \; display "Reloaded config"
# Bottom bar
set-option -g status on
# Mouse on to allow copy
#set-option -g mouse on
set -g default-terminal screen-256color
# switch windows alt+number
bind-key -n M-0 select-window -t 0
bind-key -n M-1 select-window -t 1
bind-key -n M-2 select-window -t 2
bind-key -n M-3 select-window -t 3
bind-key -n M-4 select-window -t 4
bind-key -n M-5 select-window -t 5
bind-key -n M-6 select-window -t 6
bind-key -n M-7 select-window -t 7
bind-key -n M-8 select-window -t 8
bind-key -n M-9 select-window -t 9
# Switch pane in current pane
bind -n M-h select-pane -L
bind -n M-j select-pane -D
bind -n M-k select-pane -U
bind -n M-l select-pane -R
# Toggle zoom in and zoom out ALT+Z
bind -n M-s resize-pane -Z
# Resize panes on ALT+key
bind -n M-u resize-pane -L 20
bind -n M-i resize-pane -D 10
bind -n M-o resize-pane -U 10
bind -n M-p resize-pane -R 20
# Switch pane in nested pane
bind-key -n C-a send-prefix
bind-key -n C-h send-prefix \; send-keys Left
bind-key -n C-j send-prefix \; send-keys Down
bind-key -n C-k send-prefix \; send-keys Up
bind-key -n C-l send-prefix \; send-keys Right
bind-key -n C-s send-prefix \; send-keys z # Zoom in/out in nested session
# Change timeout time (when going back and forth in panes)
set-option -g repeat-time 0
# Setup
kill-session -t main
new-session -n ranger -s main
send-keys -t main:ranger "ranger" Enter
split-window -v
split-window -h
NAME2=2
new-window -n $NAME2
send-keys -t main:$NAME2 "cd repos/" Enter
split-window -h
send-keys -t main:$NAME2 "cd repos/" Enter
split-window -v
send-keys -t main:$NAME2 "cd repos/" Enter
select-pane -L
split-window -v
send-keys -t main:$NAME2 "cd repos/" Enter
NAME3=3
new-window -n $NAME3
send-keys -t main:$NAME3 "cd repos/" Enter
split-window -h
send-keys -t main:$NAME3 "cd repos/" Enter
split-window -v
send-keys -t main:$NAME3 "cd repos/" Enter
NAME4=4
new-window -n $NAME4
send-keys -t main:$NAME4 "cd repos/" Enter
split-window -h
send-keys -t main:$NAME4 "cd repos/" Enter
split-window -v
send-keys -t main:$NAME4 "cd repos/" Enter
NAME5=5
new-window -n $NAME5
send-keys -t main:$NAME5 "cd repos/" Enter
split-window -h
send-keys -t main:$NAME5 "cd repos/" Enter
split-window -v
send-keys -t main:$NAME5 "cd repos/" Enter
NAME5=6
new-window -n $NAME6
send-keys -t main:$NAME6 "cd repos/" Enter
split-window -h
send-keys -t main:$NAME6 "cd repos/" Enter
split-window -v
send-keys -t main:$NAME6 "cd repos/" Enter
NAME7=7
new-window -n $NAME7
send-keys -t main:$NAME7 "cd repos/" Enter
split-window -h
send-keys -t main:$NAME7 "cd repos/" Enter
split-window -v
send-keys -t main:$NAME7 "cd repos/" Enter
NAME8=htop
new-window -n $NAME8
# send-keys -t main:$NAME8 "htop" Enter
NAME9=9
new-window -n $NAME9
send-keys -t main:$NAME9 "cd repos/" Enter
split-window -h
send-keys -t main:$NAME9 "cd repos/" Enter
split-window -v
send-keys -t main:$NAME9 "cd repos/" Enter
select-window -t :1