@@ -13,28 +13,64 @@ Inspired by [vim-sensible](https://github.com/tpope/vim-sensible).
13
13
- ** no overriding** of user defined settings.<br />
14
14
Your existing ` .tmux.conf ` settings are respected and they won't be changed.
15
15
That way you can use ` tmux-sensible ` if you have a few specific options.
16
- See [ feature section] ( #example-feature ) for an example.
17
- - [ source code] ( https://github.com/tmux-plugins/tmux-sensible/blob/master/sensible.tmux )
18
- is the authoritative documentation.<br />
19
- It's really not that scary and you should have a look, even if you're a
20
- tmux beginner.
21
16
22
17
### Goals
23
18
24
19
- group standard tmux community options in one place
25
20
- remove clutter from your ` .tmux.conf `
26
21
- educate new tmux users about basic options
27
22
28
- ### Example feature
23
+ ### Options
29
24
30
- Sets tmux prefix to ` Ctrl-a ` .
25
+ # utf8 is on
26
+ set -g utf8 on
27
+ set -g status-utf8 on
31
28
32
- # set prefix to `Ctrl-a`
33
- tmux set-option -g prefix C-a
34
- tmux unbind-key C-b
29
+ # address vim mode switching delay (http://superuser.com/a/252717/65504)
30
+ set -s escape-time 0
35
31
36
- Since user defined ` .tmux.conf ` settings are respected, if prefix is set to
37
- ` Ctrl-z ` - it won't be overriden!
32
+ # increase scrollback buffer size
33
+ set -g history-limit 50000
34
+
35
+ # tmux messages are displayed for 4 seconds
36
+ set -g display-time 4000
37
+
38
+ # refresh 'status-left' and 'status-right' more often
39
+ set -g status-interval 5
40
+
41
+ # set only on OS X where it's required
42
+ set -g default-command "reattach-to-user-namespace -l $SHELL"
43
+
44
+ # upgrade $TERM
45
+ set -g default-terminal "screen-256color"
46
+
47
+ # enable all mouse features for terminals that support it
48
+ setw -g mode-mouse on
49
+ set -g mouse-resize-pane on
50
+ set -g mouse-select-pane on
51
+ set -g mouse-select-window on
52
+
53
+ # emacs key bindings in tmux command prompt (prefix + :) are better than
54
+ # vi keys, even for vim users
55
+ set -g status-keys emacs
56
+
57
+ ### Key bindings
58
+
59
+ # easier and faster switching between next/prev window
60
+ bind C-p previous-window
61
+ bind C-n next-window
62
+
63
+ # source .tmux.conf as suggested in `man tmux`
64
+ bind R source-file '~/.tmux.conf'
65
+
66
+ "Adaptable" key bindings that build upon your ` prefix ` value:
67
+
68
+ # if prefix is 'C-a'
69
+ bind C-a send-prefix
70
+ bind a last-window
71
+
72
+ If prefix is ` C-b ` , above keys will be ` C-b ` and ` b ` .<br />
73
+ If prefix is ` C-z ` , above keys will be ` C-z ` and ` z ` ... you get the idea.
38
74
39
75
### Installation with [ Tmux Plugin Manager] ( https://github.com/tmux-plugins/tpm ) (recommended)
40
76
0 commit comments