Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # basic window operations
- unbind c
- bind c new-window
- unbind & # purposefully diffcult combination, better the shell's "C-d", or kill-pane
- bind & confirm-before kill-window
- unbind x # close pane (if last also the window)
- bind x confirm-before kill-pane
- # window cycling "<" or "," for previous window
- unbind ,
- bind -r , previous-window
- unbind <
- bind -r < previous-window
- unbind Left
- bind -r Left previous-window
- # ">" or "." for next window
- unbind .
- bind -r . next-window
- unbind >
- bind -r > next-window
- unbind Right
- bind -r Right next-window
- # find a window by name
- unbind f
- bind f command-prompt "find-window '%%'"
- # rename a window (gnuscreen default shortcut)
- unbind A
- bind A command-prompt "rename-window %%"
- # backspace for last active window
- unbind Tab
- bind -r Tab last-window
- # window picker
- unbind w
- bind w choose-window
- # add split side-by-side
- unbind |
- bind -r | split-window -h
- # add split top-bottom
- unbind _
- bind -r _ split-window -v
- # swap panes
- unbind {
- bind -r { swap-pane -U
- unbind }
- bind -r } swap-pane -D
- # number panes visibly
- unbind q
- bind q display-panes
- # cycle through pane layouts
- unbind Space
- bind -r Space next-layout
- # change pane focus (like vi cursor movement)
- unbind k
- bind -r k select-pane -U
- unbind j
- bind -r j select-pane -D
- unbind h
- bind -r h select-pane -L
- unbind l
- bind -r l select-pane -R
- # resize pane
- unbind '('
- bind -r '(' resize-pane -L 4
- unbind ')'
- bind -r ')' resize-pane -R 4
- unbind +
- bind -r + resize-pane -U 2
- unbind -
- bind -r - resize-pane -D 2
- # command line
- unbind :
- bind : command-prompt
- # display key bindings
- unbind ?
- bind ? list-keys
- # copy and scroll mode (see "man tmux"), and paste
- unbind [
- bind [ copy-mode
- unbind ]
- bind -r ] paste-buffer -s \015 # sadly '-r' doesnt work here, hopefully one day it does
- unbind PPage
- bind PPage copy-mode -u # to copymode and one page up (pgup/dn passed on)
- # additional keys to use in copy (scroll) mode
- bind -t emacs-copy Enter copy-selection
- bind -t emacs-copy Space begin-selection
- # apply the config file again...
- unbind r
- bind r source-file /etc/tmux.conf
- # page up and down
- # --> this has to be done for the shell, vi aparently works well.
- # TODO:
- # * keybindings for detaching/attaching
- # * for session/client/buffer management
- # * for buffer filling and pasting
- # * mouse scroll fix
- # * mouse click focus
- # * alt-tab style feature request
- # * select+move splitters (need splitter highlighting)
- # * quake style "toggle terminal from above", bound to "~"
- # its not logic to have the most left 'tab' on the very right of the key strip
- set -g base-index 1
- # should fix scrolling issues (with shift pgup/dn)
- set -g terminal-overrides 'xterm*:smcup@:rmcup@'
- # some general config options
- set -g default-terminal "screen-256color"
- set -g history-limit 10000
- set -g repeat-time 800
- set -g status on
- set -g status-keys emacs
- set -g bell-action any
- set -g visual-bell on
- setw -g monitor-activity on # monitor activity of all windows
- setw -g monitor-content on # monitor for content changes as well
- set -g visual-activity off # no flashy messages in my status line please! (watch the window attrs '#-*!+' instead)
- set -g visual-content off # idem
- setw -g mode-keys emacs
- setw -g mode-mouse off # on prevents mouse select on the terminal
- set -g mouse-select-pane off # on prevents mouse select in panes
- setw -g utf8 on
- # window title
- set -g set-titles on
- setw -g automatic-rename on
- # status bar
- set -g status-utf8 on
- set -g status-justify centre
- set -g status-interval 5
- set -g status-left-length 30
- set -g status-left ''
- set -g status-right '#[fg=blue,bold]#H#[default] #[fg=green]» #[fg=yellow]#(cut -d " " -f 1-3 /proc/loadavg) #[fg=green]» #[fg=cyan]#S#[default] #[fg=green]» #[fg=red]#(acpi | cut -d "," -f 2 | sed "s/^ *//g") #[fg=green]» #[fg=magenta]%R#[default]'
- set -g status-right-length 45
- # colors
- set -g message-bg default
- set -g message-fg green
- set -g status-bg default
- set -g status-fg green
- setw -g window-status-bg default
- setw -g window-status-fg green
- setw -g window-status-alert-attr none
- setw -g window-status-alert-bg default
- setw -g window-status-alert-fg green
- setw -g window-status-current-bg red
- setw -g window-status-current-fg black
Advertisement
Add Comment
Please, Sign In to add comment