[]tmux常用配置

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/u012335044/article/details/83411399
保存一份tmux常用配置:
# set -g mode-mouse on
# 设置滚屏
# set-window-option -g mode-mouse on

# 如果喜欢给窗口自定义命名,那么需要关闭窗口的自动命名
set-option -g allow-rename off
# 如果对 vim 比较熟悉,可以将 copy mode 的快捷键换成 vi 模式
set-window-option -g mode-keys vi
# 系统剪切板共享
#set-option -g default-command "reattach-to-user-namespace -l zsh"

# 用鼠标切换窗口、调节分屏大小
# setw -g mouse-resize-pane on
# set-window-option -g mouse-select-pane on
# setw -g mode-mouse on
# setw -g mouse-select-window on
## 设置复制模式
 setw -g mode-keys vi
# bind ` copy-mode
# unbind [
# unbind p
# bind p paste-buffer
# bind -t vi-copy v begin-selection
# bind -t vi-copy y copy-selection
bind -t vi-copy Escape cancel
bind y run "tmux save-buffer - | reattach-to-user-namespace pbcopy"

# 下面是自己的一些配置,可删可不删
bind r source-file ~/.tmux.conf \; display "配置文件已成功加载完毕!"
bind | split-window -h
bind - split-window -v
# set -g default-ternimal "screen-256color"
set -g status-fg white
set -g status-bg black
setw -g window-status-fg magenta
setw -g window-status-bg default
setw -g window-status-attr dim
setw -g window-status-current-fg white
setw -g window-status-current-bg red
setw -g window-status-current-attr bright
set -g pane-border-fg green
set -g pane-border-bg yellow
set -g pane-active-border-fg white
set -g pane-active-border-bg cyan
set -g message-fg white
set -g message-bg black
set -g message-attr bright

set -g status-left-length 36
set -g status-left "#[fg-White] Session: #S #[fg=cyan]#P"

set -g status-interval 60
set -g status-justify centre
setw -g monitor-activity on
set -g visual-activity on


#zzk
#bind -t vi-copy v begin-selection 
#bind -t vi-copy y copy-pipe 'xclip -selection clipboard >/dev/null'

#bind -t vi-copy v begin-selection
#bind -t vi-copy y copy-selection
# bind -t vi-copy Escape cancel
# bind y run "tmux save-buffer - | reattach-to-user-namespace pbcopy"
#
#

setw -g mouse-resize-pane on
setw -g mouse-select-pane on
setw -g mouse-select-window on
setw -g mode-mouse on

猜你喜欢

转载自blog.csdn.net/u012335044/article/details/83411399