1
0
mirror of https://shylinux.com/x/ContextOS synced 2025-04-25 16:58:06 +08:00

opt tmux.conf

This commit is contained in:
shaoying 2019-10-31 04:35:03 +08:00
parent b5ffb8f179
commit 096a245c1e

66
etc/conf/tmux.conf Normal file
View File

@ -0,0 +1,66 @@
# 配置管理{{{
set -g prefix C-s
set -g base-index 1
set -g allow-rename off
set -g renumber-windows on
set -g display-time 5000
set -g display-panes-time 5000
set -g mode-keys vi
set -g history-limit 1000
setw -g pane-base-index 1
# }}}
# 会话管理{{{
bind s choose-tree -u
bind q confirm-before "detach-client"
# }}}
# 窗口管理{{{
bind c new-window
bind b break-pane
bind B join-pane
bind B choose-tree "join-pane -v -t %%"
bind e command-prompt -p "window new name:" "rename-window '%%'"
bind m choose-tree -suw -c "swap-window -t %%"
bind o last-window
bind n next-window
bind p previous-window
# }}}
# 面板管理{{{
bind i display-panes
bind x confirm-before -p "kill-pane #P? (y/n)" kill-pane
bind u split-window -c "#{pane_current_path}"
bind v split-window -h -c "#{pane_current_path}"
bind U split-window -f -c "#{pane_current_path}"
bind V split-window -f -h -c "#{pane_current_path}"
bind h select-pane -L
bind l select-pane -R
bind j select-pane -D
bind k select-pane -U
bind C-o confirm-before -p "kill all other pane(y/n)?" "kill-pane -a"
bind C-h command-prompt -p "size:" "resize-pane -L %%"
bind C-l command-prompt -p "size:" "resize-pane -R %%"
bind C-j command-prompt -p "size:" "resize-pane -D %%"
bind C-k command-prompt -p "size:" "resize-pane -U %%"
bind C-m display-panes "swap-pane -t %%"
bind C-u display-panes "move-pane -v -t %%"
bind C-v display-panes "move-pane -h -t %%"
# }}}
# 缓存管理{{{
bind C-s copy-mode -e
bind C-d clear-history
bind a choose-buffer
bind z paste-buffer
# }}}
# 命令管理{{{
bind Space command-prompt
bind ! command-prompt "run-shell %%"
bind @ confirm-before "source-file ~/.tmux.conf"
# }}}