Browse Source

Update tmux.conf, refactoring and use tpm

Emmanuel Bouthenot 4 years ago
parent
commit
ce42404394
1 changed files with 25 additions and 15 deletions
  1. 25 15
      .tmux.conf

+ 25 - 15
.tmux.conf

@@ -11,10 +11,17 @@
 #
 # terminal type, history size, env
 #
+
+set -g default-terminal "screen-256color"
 set -g xterm-keys on
 set -g history-limit 102400
 set -g update-environment "DISPLAY WINDOWID SSH_AUTH_SOCK SSH_AGENT_PID SSH_CONNECTION GPG_AGENT_INFO"
 
+set -s escape-time 0
+set -g display-time 4000
+set -g focus-events on
+set -g aggressive-resize on
+
 ### Backport some “screen” setting ###
 #
 # the magic key is Ctrl-a instead of Ctrl-b (the default)
@@ -45,25 +52,28 @@ bind a send-prefix
 #
 bind h split-window
 bind v split-window -h
+
 #
-# enter copy mode
+# Color Themes (managed by tpm)
 #
-unbind [
-bind * copy-mode
+set -g @plugin "arcticicestudio/nord-tmux"
 
-### Decoration settings ###
 #
-# some colors
+# Plugins (managed by tpm)
 #
-set -g status-bg black
-set -g status-fg white
-#set -g set-titles-string '#H #S #I #P #W #T' # window number,program name,active (or not)
-set-window-option -g window-status-current-fg red
-set-window-option -g window-status-current-bg default
+set -g @plugin 'tmux-plugins/tmux-copycat'
+set -g @plugin 'tmux-plugins/tmux-prefix-highlight'
+set -g @plugin 'tmux-plugins/tmux-urlview'
+set -g @plugin 'tmux-plugins/tmux-sidebar'
+
+#
+# Plugins options
+#
+set -g @sidebar-tree-command 'tree -C'
+set -g @sidebar-tree-pager 'less -r'
+set -g @sidebar-tree-width '50'
+
 #
-# status bar settings
+# Initialize and run tpm
 #
-set -g status-interval 60
-set -g status-left '#[fg=green]#(hostname)#[default] '
-set -g status-right "#[fg=yellow]up: #(uptime|cut -d ' ' -f 4-| sed 's/ days, /d,/ ; s/ load average: /load: /')#[default] #[fg=green]%H:%M %d-%m-%Y#[default] (#S)"
-set -g status-right-length 70
+run "~/.tmux/plugins/tpm/tpm"