Last active
June 9, 2022 02:25
-
-
Save chhaileng/0cd21659a26b6703badb08c549f702dc to your computer and use it in GitHub Desktop.
My tmux configuration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ~/.tmux.conf | |
# Change prefix | |
set -g prefix C-a | |
bind C-a send-prefix | |
unbind C-b | |
# Join windows | |
bind-key j command-prompt -p "join pane from:" "join-pane -s '%%'" | |
bind-key s command-prompt -p "send pane to:" "join-pane -t '%%'" | |
# Search mode | |
set-window-option -g mode-keys vi | |
set-option -g history-limit 3000 | |
set -g default-terminal "screen-256color" | |
#bind c new-window -c "#{pane_current_path}" | |
bind '"' split-window -c "#{pane_current_path}" | |
bind % split-window -h -c "#{pane_current_path}" | |
# Hack the box environment | |
set-option -g status-left-length 30 | |
set -g status-interval 5 | |
set-option -g status-left "[#S - #(echo `if test -f /sys/class/net/tun0/operstate; then ifconfig tun0|grep inet|xargs|cut -d' ' -f2; else echo VPN Not Connected; fi`)] " | |
# Use for save tmux session | |
# git clone https://github.com/tmux-plugins/tmux-resurrect | |
# Prefix + Ctrl + s => to save | |
# Prefix + Ctrl + r => to restore | |
run-shell /opt/tmux-resurrect/resurrect.tmux |
Author
chhaileng
commented
Jun 9, 2022
•
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment