<root> / tmux.conf (edd31e9feb0455ca0ca9ac8cc0d82572ea18597a) (2,566B) (mode 100644) [raw]
# Meaning of aliases:
#  bind   -> bind-key
#  unbind -> unbind-key
#  set    -> set-option
#  set -w -> set-window-option

# use ctrl-s as prefix key
set -g prefix C-s
unbind C-b
bind C-s send-prefix

# use vi-like shortcuts in copy modes
set -gw mode-keys vi

# don't wrap search in copy mode
set -g wrap-search off

# don't wait for the next character after escape key
set -g escape-time 0

# setup default type of terminal
set -g default-terminal "tmux-256color"

# show pane numbers for two seconds
set -g display-panes-time 2000

# store more of buffer history
set -g history-limit 100000

# automatically eliminate gaps in numbers of windows (tabs)
set -g renumber-windows on

# use vi-line shortcuts to yank text in copy-mode
bind -T copy-mode-vi v   send-keys -X begin-selection
bind -T copy-mode-vi V   send-keys -X select-line
bind -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind -T copy-mode-vi y   send-keys -X copy-selection

# reload config (prefix + r)
bind r source ~/.tmux.conf \; \
       display "Configuration reloaded!"

# rebind vertical and horizontal splitting shortcuts and preserve CWD
unbind %
unbind '"'
bind | split-window -c "#{pane_current_path}" -h
bind - split-window -c "#{pane_current_path}" -v
# redefine a window creation to preserve CWD
bind c new-window -c "#{pane_current_path}"

# duplicate prefix+n/p keys with prefix+<c-n>/<c-p>
bind C-n next-window
bind C-p previous-window

# move between panes using prefix + h/j/k/l
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R

# resize pane using prefix + H/J/K/L
bind -r H resize-pane -L 5
bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5

# toggle between two last visited windows
bind ' ' last-window

# configure borders colour scheme
set -g pane-border-style "bg=black fg=colour235"
set -g pane-active-border-style "bg=colour235 fg=white"

# configure status bar colour scheme
set -gw status-style "bg=colour235 fg=white bold"
set -gw window-status-style "bg=colour235 fg=white"
set -gw window-status-current-style "bg=colour235 fg=colour248 bold reverse"

# configure status bar look
set -g status-justify centre
set -g status-right ''
set -g status-right-length 50

# display status bar at the top
set -g status-position top

# copy copy-mode selection into primary selection of X
bind -T copy-mode-vi c send-keys -X copy-pipe-and-cancel "xsel --primary --input"
# copy copy-mode selection into clipboard of X
bind -T copy-mode-vi C send-keys -X copy-pipe-and-cancel "xsel --clipboard --input"
Hints

Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://code.reversed.top/user/xaizek/dotfiles

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@code.reversed.top/user/xaizek/dotfiles

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a pull request:
... clone the repository ...
... make some changes and some commits ...
git push origin master