-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
85 lines (67 loc) · 2.27 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
#
# .tmux.conf
#
####################################################
set -g default-terminal "screen-256color"
set -g terminal-overrides 'xterm:colors=256'
### Options
set-window-option -g mode-keys vi
set-window-option -g automatic-rename on
set-option -g mouse on
set-option -g base-index 1
### Keybindings
unbind-key w
unbind-key l
unbind-key M-n
unbind-key M-p
unbind-key C-t
unbind-key C-b
unbind-key Up
unbind-key Down
unbind-key Left
unbind-key Right
bind-key -r k select-pane -U
bind-key -r j select-pane -D
bind-key -r h select-pane -L
bind-key -r l select-pane -R
bind-key C-r source-file ~/.tmux.conf
# 矩形選択
bind -T copy-mode-vi C-v send -X rectangle-toggle
# clipboard buffer
bind y choose-buffer
# Popwin
bind-key w command-prompt "split-window -p 65 'exec man %%'"
# Prefix key
set-option -g prefix C-t
bind-key C-t send-prefix
# Copy Mode
bind-key -T copy-mode-vi v send -X begin-selection
bind-key -T copy-mode-vi Enter send -X copy-selection
# for Mac
if-shell "uname | grep -q Darwin" \
'set-option -g default-command "reattach-to-user-namespace -l ${SHELL}"'
if-shell "uname | grep -q Darwin" \
'bind-key -T copy-mode-vi y send -X copy-pipe-and-cancel "reattach-to-user-namespace pbcopy"'
# for Linux
if-shell "uname | grep -q Linux" \
"bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xsel -ib'"
### Status Line
set-option -g status-style bg=black
### Current Window
set-window-option -g window-status-current-style fg=magenta,bg=black
set-window-option -g window-status-current-style bright
### Window Name
set-window-option -g window-status-current-format "#I > #W "
set-window-option -g window-status-format "#I > #W "
### Pane
set -g pane-active-border-style fg=green # アクティブペインのボーダー
set -g pane-border-style fg=white # 非アクティブペインのボーダー
### Status Line (include tmux-powerline)
set -g terminal-overrides 'xterm:colors=256'
set-option -g status-position top
if-shell "uname | grep -q Darwin" \
'run-shell "powerline-daemon -q"'
if-shell "uname | grep -q Darwin" \
'source ~/.config/powerline/bindings/tmux/powerline.conf'
set -sg escape-time 0
set-window-option -g window-status-current-format "#[fg=colour235, bg=colour198]⮀#[fg=colour255, bg=colour198] #I > #W #[fg=colour255, bg=colour235]⮀"