You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
dotfiles/tmux.conf

81 lines
2.2 KiB

# allow resize bigger than the smallest client
set -g aggressive-resize on
# allow setting overrides of C-Up, ..., C-Right, and other stuff possibly...
set -g terminal-overrides 'xterm*:smcup@:rmcup@'
# ncurses not polluting scroll history
set -g alternate-screen on
# command prefix
unbind C-b
set -g prefix C-a
bind a send-prefix
bind-key C-a last-window
# basic settings
set -g history-limit 30000
set-option -g default-shell /usr/bin/zsh
set-window-option -g utf8 on
set -g default-terminal "xterm"
# vi mode
set-window-option -g mode-keys vi
set-option -g status-keys vi
bind-key -t vi-copy 'v' begin-selection
bind-key -t vi-copy 'y' copy-selection
# escape mode
unbind [
bind Escape copy-mode
set -s escape-time 50
# switch windows
bind -r j previous-window
bind -r k next-window
# splitting
unbind %
unbind '"'
bind + split-window -h # horizontal split
bind - split-window -v # vertical split
bind -r h run "tmux select-pane -L"
bind -r j run "tmux select-pane -D"
bind -r k run "tmux select-pane -U"
bind -r l run "tmux select-pane -R"
bind -r Down resize-pane -D 2
bind -r Up resize-pane -U 2
bind -r Left resize-pane -L 2
bind -r Right resize-pane -R 2
bind-key b command-prompt -p "create pane from:" "join-pane -s ':%%'"
bind-key v command-prompt -p "send pane to:" "join-pane -t ':%%'"
# window title
set-option -g set-titles on
set-option -g set-titles-string '[#H]: #W'
set-window-option -g automatic-rename off
# no visual activity
set -g visual-activity off
set -g visual-bell off
# status bar
set-option -g status-utf8 on
set-option -g status-justify left
set-option -g status-bg black
set-option -g status-fg cyan
set-option -g status-interval 5
set-option -g status-left-length 0
set-option -g status-right-length 80
set-option -g status-left ''
set-option -g status-right '#[fg=blue,bold]#H #[fg=green,bold]|#[fg=black,bold]#(uptime | rev | cut -d":" -f1 | rev | sed s/,//g ) #[fg=green,bold]| #[fg=blue,bold]%d.%m.%y %H:%M'
set-window-option -g window-status-current-fg black
set-window-option -g window-status-current-bg green
# clock
set-window-option -g clock-mode-colour cyan
set-window-option -g clock-mode-style 24
# copy and paste
bind C-p run "tmux set-buffer \"$(xclip -o)\"; tmux paste-buffer"
bind C-y run "tmux show-buffer | xclip -i"