tmux 的最佳默认键绑定是什么?为什么有时使用 emacs 有时使用 vim(在 Linux Mint 12 上)?Ctrl-b 没问题,但这与 bash shell 和 emacs 有点冲突。
jus*_*don 10
我在相关帖子中找到了一个很好的答案:屏幕或 tmux 的冲突最少的前缀/转义序列是什么?
我已经使用了 Ctrl-\。下面是我的 ~/.tmux-conf:
set-window-option -g mode-keys vi
set-window-option -g window-status-current-bg blue
set-window-option -g automatic-rename on
set-option -g status-keys vi
set-option -g history-limit 100000
set-option -g base-index 1
set-option -s escape-time 0
setw -g mode-mouse on
set-option -g mouse-select-pane on
# We won't worry about sending C-\ to any programs
# bind-key C-\ send-prefix
# hit C-\ twice to go to last window
bind-key C-\ last-window
bind-key b set-option status
bind-key / command-prompt "split-window 'exec man %%'"
# vim's definition of a horizontal/vertical split is reversed from tmux's
bind s split-window -v
bind v split-window -h
# move around panes with hjkl, as one would in vim after pressing ctrl-w
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# resize panes like vim
bind < resize-pane -L 10
bind > resize-pane -R 10
bind - resize-pane -D 10
bind + resize-pane -U 10
# C-b is not acceptable, due to emacs, bash, and vim
unbind-key C-b
set-option -g prefix C-\
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
10824 次 |
最近记录: |