From c54ecaab0240e3cba4535111b7e7410829e9d2ad Mon Sep 17 00:00:00 2001 From: Laily Date: Sun, 21 Oct 2018 00:31:32 +0800 Subject: [PATCH] modify tmux.conf --- .tmux.conf | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) mode change 120000 => 100644 .tmux.conf diff --git a/.tmux.conf b/.tmux.conf deleted file mode 120000 index ad76979..0000000 --- a/.tmux.conf +++ /dev/null @@ -1 +0,0 @@ -.tmux/.tmux.conf \ No newline at end of file diff --git a/.tmux.conf b/.tmux.conf new file mode 100644 index 0000000..6caf243 --- /dev/null +++ b/.tmux.conf @@ -0,0 +1,27 @@ +setw -g mode-keys vi +unbind ^b +set -g prefix 'C-a' +bind r source-file ~/.tmux.conf \; display-message "Config reloaded" + +# 切分面板 +# unbind '"' +bind - splitw -v -c '#{pane_current_path}' +# unbind % +bind | splitw -h -c '#{pane_current_path}' + +set-option -g mouse on + +# 绑定hjkl键为面板切换的上下左右键 +bind -r k select-pane -U # 绑定k为↑ +bind -r j select-pane -D # 绑定j为↓ +bind -r h select-pane -L # 绑定h为← +bind -r l select-pane -R # 绑定l为→ + +# 绑定Ctrl+hjkl键为面板上下左右调整边缘的快捷指令 +bind -r K resizep -U 10 # 绑定Ctrl+k为往↑调整面板边缘10个单元格 +bind -r J resizep -D 10 # 绑定Ctrl+j为往↓调整面板边缘10个单元格 +bind -r H resizep -L 10 # 绑定Ctrl+h为往←调整面板边缘10个单元格 +bind -r L resizep -R 10 # 绑定Ctrl+l为往→调整面板边缘10个单元格 + +# 设置tmux的延迟,文档说当有干扰的时候可以设置这个参数,比如影响vim编辑的时候 +set -s escape-time 1