# File: $HOME/.tmux.conf # Purpose: Setup file for the terminal emulator TMUX # Availability: This file is available as # http://www.guckes.net/Setup/tmux.conf # Author: Sven Guckes tmux-config @ guckes.net # Latest change: Sat Nov 21 10:42:23 CET 2020 # Changes: # Thu Nov 19 12:42:23 CET 2020 # Tue Jan 17 03:00:00 CET 2017 # Sat Dec 31 14:42:23 CET 2016 # Fr Jun 05 23:23:23 CEST 2015 # [2011-03-28] https://mutelight.org/practical-tmux by Brandur Leach # reload the config file: # source-file ~/.tmux.conf # set the prefix command" to CTRL-A # (instead of the default CTRL-B) # probably useful for people # changing over from Gnu SCREEN unbind C-b set -g prefix C-a # 2020-11-19 # together with c-a as the prefix # this makes "c-a c-a" toggle between the # current and previous window like screen does # with the ":other" command. halleluja! :-) bind c-a last-window # seeting the default command and shell: set -g default-command /bin/zsh set -g default-shell /bin/zsh # you may want to add "--login" as a parameter # to make each shell a "login shell" # PREFIX = CTRL-B (default) # PREFIX c Create new window # PREFIX d Detach current client # PREFIX l Move to previously selected window # PREFIX n Move to the next window # PREFIX p Move to the previous window # PREFIX & Kill the current window # PREFIX , Rename the current window # PREFIX % Split the current window into two panes # PREFIX q Show pane numbers (used to switch between panes) # PREFIX o Switch to the next pane # PREFIX ? List all keybindings # NUMBERS # begin window index from 1 instead of 0 # set -g base-index 1 set -g base-index 0 # actually, i so much used to screen's "index 0" # that i have removed this setting. o_O # old habits are hard to break... # Note: Screen cannot do this, ie "start at one". # the window numbering in screen # *always* starts with zero. *sigh* # begin pane index by 1 instead of 0 set -g pane-base-index 1 # STATUSBAR # 2020-11-19 # set status line in white on blue: set -g status-bg blue set -g status-fg white # MOUSE # select window using the mouse # set-option -ag mouse-select-window on # resize pane using the mouse # set-option -ag mouse-resize-pane on # Key Bindings # reload the configuration! bind r source-file ~/.tmux.conf \; display "Reloaded!" # splitting windows into panes (think "sub-windows") bind | split-window -h bind - split-window -v # 2015-06-05 # Terminal Colors set-option -g default-terminal "screen-256color" # 2017-01-07 set-option -g set-titles on # 2017-01-17 # change "default-COMMAND" to get a # different, well, default command". :-) # set-option -g default-command /bin/bash # set-option -g default-shell /bin/bash # 2020-11-19 # show the status bar on top line of screen! set status-position top # .. now how to also display tmux with its version number? # # toggle display of status bar bind _ set-option status # 2020-11-19 # enter copy-mode not only with [ but also with c-[ (aka ESC) bind c-[ copy-mode # mini HOWTO copy mode # (1) PREFIX [ enter copy mode # (2) MOVE AROUND.. (emacs/vi commands) # (3) PREFIX SP begin selection here # (4) PREFIX ENTER end selection here -> goes into buffer # (5) PREFIX ] paste from buffer # more... # set-option window-style 'bg=black fg=red' # 2020-11-21 turn on acticity notification for all windows: # set-option -wt:0 monitor-activity on set-option -w monitor-activity on # vim: set tw=70 et fenc=utf-8 sw=4 comments=\:\": THPXRF: EOF