Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ###-------------###
- ### tmux.conf ###
- ###-------------###
- ## Reload tmux.conf configuration file
- ## Note: alternative way to reload the configuration file:
- ## Method 1: Run from command line: tmux source-file ~/.tmux.conf
- ## Method 2: In any tmux sessions: [prefix Ctrl-b] : source-file /usr/local/etc/tmux.conf
- ## Method 3: bind the source-file command with a key like following line, then you type: ctrl-b-r
- bind R source-file ~/.tmux.conf
- ###################################################################################
- ### Keybindngs ###
- ## Note: key meaning
- ## C- means ctrl-, so C-x is ctrl-x.
- ## M- means meta (generally left-alt or escape)-, so M-x is left-alt-x.
- ## Set the prefix to ^A.
- ## Note: the default prefix is Ctrl-b.
- unbind C-b
- set -g prefix ^A
- bind a send-prefix
- ## unbind existing tmux key-bindings
- unbind '"'
- unbind '#'
- unbind &
- unbind ,
- unbind -
- unbind :
- unbind =
- unbind ?
- unbind [
- unbind o
- unbind p
- unbind r
- unbind s
- unbind t
- unbind w
- unbind x
- unbind Up
- unbind Down
- unbind M-Up
- unbind M-Down
- unbind C-Up
- unbind C-Down
- ## lock the session
- bind ^X lock-server
- bind x lock-server
- ## command prompt to send specific tmux commands
- bind : command-prompt
- ## spawn a new window
- bind ^C new-window
- bind c new-window
- ## copy ^[ [
- bind ^[ copy-mode
- bind [ copy-mode
- ## paste ] ^]
- bind ] paste-buffer
- bind ^] paste-buffer
- ## " windowlist -b
- bind '"' choose-window
- ## detach
- bind ^D detach
- ## meta key
- bind a send-prefix
- ## last window
- bind ^A last-window
- ## next term
- bind ^N next-window
- bind n next-window
- ## previous term
- bind ^P previous-window
- bind p previous-window
- ## print help
- bind ? list-keys
- ## print a list of windows
- bind ^W list-windows
- bind w list-windows
- ## rename the current window
- bind A command-prompt "rename-window %%"
- ## kill the current window
- bind K kill-window
- bind k kill-window
- ## refresh the current window
- bind ^L refresh-client
- bind l refresh-client
- ## quit the current session
- bind \ kill-server
- ## Mouse On/Off ## {
- ## Mouse On by default
- set -g mode-mouse on
- set -g mouse-resize-pane on
- set -g mouse-select-pane on
- set -g mouse-select-window on
- ##Toggle mouse on with <prefix>m
- bind m \
- set -g mode-mouse on \;\
- set -g mouse-resize-pane on \;\
- set -g mouse-select-pane on \;\
- set -g mouse-select-window on \;\
- display 'Mouse: ON'
- ## Toggle mouse off with <prefix>M
- bind M \
- set -g mode-mouse off \;\
- set -g mouse-resize-pane off \;\
- set -g mouse-select-pane off \;\
- set -g mouse-select-window off \;\
- display 'Mouse: OFF'
- ## End Mouse On/Off ## }
- # move x clipboard into tmux paste buffer
- bind C-p run "tmux set-buffer \"$(xclip -o)\"; tmux paste-buffer"
- ## move tmux copy buffer into x clipboard
- bind C-y run "tmux show-buffer | xclip -i"
- ###---------------------------
- ## Split windows like vim
- ## 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 5
- bind > resize-pane -R 5
- bind - resize-pane -D 5
- bind + resize-pane -U 5
- ## bind : to command-prompt like vim
- ## this is the default in tmux already
- bind : command-prompt
- ## vi-style controls for copy mode
- setw -g mode-keys vi
- ###################################################################################
- ### $TERM Options ###
- ## 256 color Terminal
- set -g default-terminal screen-256color
- ## Instructs tmux to expect UTF-8 sequences to appear in this window.
- setw -g utf8 on
- ## Instruct tmux to treat top-bit-set characters in the status-left and status-right strings as UTF-8;
- set -g status-utf8 on
- ## Fix for setting URxvt Window Title
- set -ga terminal-overrides ",screen*,rxvt*:XT"
- ## Enable italic font support for rxvt-unicode
- #set -g terminal-overrides "rxvt-unicode-256color:sitm@"
- ## Enable mouse scrolling support in tmux
- set-window-option -g mode-mouse on
- ## Enable system audible bell
- set-option -g bell-action any
- ###################################################################################
- ### Misc Options ###
- ## Set the maximum number of lines held in window history.
- set -g history-limit 5000
- ## Set Window Titles
- setw -g set-titles on
- setw -g set-titles-string "#S:#I.#P :#W - #T"
- setw -g automatic-rename on
- ###################################################################################
- ### Status Bar Options ###
- ## Enable Status Bar
- set-option -g status on
- ## refresh status bar in seconds
- #set-option -g status-interval 15
- ## Set window notifications
- setw -g monitor-activity on
- #set -g visual-activity on
- ###-----------------------------
- # settings copied from output of tmuxline_setup
- set -g status-bg "colour0"
- set -g message-command-fg "colour7"
- set -g status-justify "centre"
- set -g status-left-length "100"
- set -g status "on"
- set -g pane-active-border-fg "colour5"
- set -g message-bg "colour11"
- set -g status-right-length "100"
- set -g status-right-attr "none"
- set -g message-fg "colour7"
- set -g message-command-bg "colour11"
- set -g status-attr "none"
- set -g pane-border-fg "colour11"
- set -g status-left-attr "none"
- setw -g window-status-fg "colour10"
- setw -g window-status-attr "none"
- setw -g window-status-activity-attr "underscore"
- setw -g window-status-separator ""
- setw -g window-status-bg "colour0"
- set -g status-left "#[fg=colour15,bg=colour14,bold] #S #[fg=colour14,bg=colour11,nobold,nounderscore,noitalics]/#[fg=colour7,bg=colour11] #F #[fg=colour11,bg=colour0,nobold,nounderscore,noitalics]#[fg=colour10,bg=colour0] #W #[fg=colour0,bg=colour0,nobold,nounderscore,noitalics]"
- set -g status-right "#[fg=colour5,bg=colour0] \\m/ #[fg=colour10,bg=colour0]#(mpc current | cut -c 1-30) #[fg=colour3,bg=colour0]#(sysctl -n dev.cpu.0.temperature)#[fg=colour0,bg=colour0,nobold,nounderscore,noitalics]#[fg=colour10,bg=colour0]%a #[fg=colour11,bg=colour0,nobold,nounderscore,noitalics]#[fg=colour7,bg=colour11] %b %d %R #[fg=colour14,bg=colour11,nobold,nounderscore,noitalics]#[fg=colour15,bg=colour14] #H "
- setw -g window-status-format "#[fg=colour0,bg=colour0,nobold,nounderscore,noitalics]#[default] #I #W #[fg=colour0,bg=colour0,nobold,nounderscore,noitalics]"
- setw -g window-status-current-format "#[fg=colour0,bg=colour11,nobold,nounderscore,noitalics]#[fg=colour7,bg=colour11] #I #W #[fg=colour11,bg=colour0,nobold,nounderscore,noitalics]"
- ###-----------------------------
- ## pane number display
- set-option -g display-panes-active-colour '#268bd2' #orange
- set-option -g display-panes-colour '#586e75' #blue
- ###################################################################################
- ### Launch Commands Configuration ###
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement