Last active
February 2, 2020 12:37
-
-
Save aagontuk/d42e4b422f41db738b9acced3118c814 to your computer and use it in GitHub Desktop.
My tmux configuration - RAW: tiny.cc/sfinix-tmux
This file contains hidden or 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
| # Remap prefix from c-b to c-space | |
| unbind C-b | |
| set-option -g prefix C-Space | |
| bind-key C-Space send-prefix | |
| # Open tmux config file in vim new window | |
| unbind e | |
| bind e new-window -n '~/.tmux.conf' "sh -c 'vim ~/.tmux.conf' && tmux source ~/.tmux.con" | |
| # Modern colors | |
| set -g default-terminal screen-256color | |
| # Status Bar configuration | |
| # Refresh every 5 seconds | |
| set -g status-interval 5 | |
| # Status color | |
| set-option -g status-style bg=colour3,fg=colour0 | |
| # Status messeges | |
| # You need to install following packages: acpi | |
| set-option -g status-right "#(~/bat_status.sh)\t \ | |
| %b-%d-%y \ | |
| %H:%M:%S" | |
| # Vim like binding for movement | |
| bind-key h select-pane -L | |
| bind-key j select-pane -D | |
| bind-key k select-pane -U | |
| bind-key l select-pane -R | |
| # Vim like binding in copy mode too! | |
| bind-key -T copy-mode h send-key -X cursor-left | |
| bind-key -T copy-mode j send-key -X cursor-down | |
| bind-key -T copy-mode k send-key -X cursor-up | |
| bind-key -T copy-mode l send-key -X cursor-right | |
| # Rotate window | |
| bind-key C-w rotate-window | |
| # Change cwd | |
| bind-key / attach -c "#{pane_current_path}" | |
| # Create new window and split in cwd | |
| bind-key '"' split-window -c "#{pane_current_path}" | |
| bind-key % split-window -h -c "#{pane_current_path}" | |
| bind-key c new-window -c "#{pane_current_path}" | |
| # Move pane to a window | |
| # bind-key j command-prompt -p "Move pane to:" "join-pane -t ':%%'" | |
| # Plugins | |
| set -g @plugin 'tmux-plugins/tpm' | |
| set -g @plugin 'tmux-plugins/tmux-sensible' | |
| set -g @plugin 'tmux-plugins/tmux-resurrect' | |
| # Initialize TMUX plugin manager | |
| run -b '~/.tmux/plugins/tpm/tpm' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment