我的 tmux 配置文件



 1 set -g status-right ''
 2 bind | split-window -h
 3 bind _ split-window -v
 4 set -g mouse-select-pane off
 5 set -g default-terminal "screen-256color"
 6 set -g display-time 2500
 7 setw -g xterm-keys on
 8 set -g base-index 1
 9 
10 # confirm before killing a window or the server
11 bind-key k confirm kill-window
12 bind-key K confirm kill-server
13 
14 # toggle statusbar
15 bind-key b set-option status
16 
17 # ctrl+left/right cycles thru windows
18 # bind-key -n C-right next
19 # bind-key -n C-left prev
20 
21 # open a man page in new window
22 bind / command-prompt "split-window 'exec man %%'"
23 
24 # quick view of processes
25 bind '~' split-window "exec top"
26 
27 # scrollback buffer n lines
28 set -g history-limit 5000
29 
30 # listen for activity on all windows
31 set -g bell-action any
32 
33 # on-screen time for display-panes in ms
34 set -g display-panes-time 2000
35 
36 # start window indexing at one instead of zero
37 set -g base-index 1
38 
39 # enable wm window titles
40 set -g set-titles on
41 
42 # wm window title string (uses statusbar variables)
43 set -g set-titles-string "tmux.#I.#W"
44 
45 
46 # $Id: vim-keys.conf,v 1.2 2010-09-18 09:36:15 nicm Exp $
47 #
48 # vim-keys.conf, v1.2 2010/09/12
49 #
50 # By Daniel Thau.  Public domain.
51 #
52 # This configuration file binds many vi- and vim-like bindings to the
53 # appropriate tmux key bindings.  Note that for many key bindings there is no
54 # tmux analogue.  This is intended for tmux 1.3, which handles pane selection
55 # differently from the previous versions
56 
57 # split windows like vim
58 # vim's definition of a horizontal/vertical split is reversed from tmux's
59 bind s split-window -v
60 bind v split-window -h
61 
62 # move around panes with hjkl, as one would in vim after pressing ctrl-w
63 bind h select-pane -L
64 bind j select-pane -D
65 bind k select-pane -U
66 bind l select-pane -R
67 
68 # resize panes like vim
69 # feel free to change the "1" to however many lines you want to resize by, only
70 # one at a time can be slow
71 bind < resize-pane -L 1
72 bind > resize-pane -R 1
73 bind - resize-pane -D 1
74 bind + resize-pane -U 1
75 
76 # bind : to command-prompt like vim
77 # this is the default in tmux already
78 bind : command-prompt
79 
80 # vi-style controls for copy mode
81 setw -g mode-keys vi

 

posted on 2013-03-30 15:57  David Young 杨博华  阅读(763)  评论(0编辑  收藏  举报

导航