Last active
January 17, 2017 17:24
-
-
Save michaelvobrien/3607824 to your computer and use it in GitHub Desktop.
Tmux Remote
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
################################################## | |
# set-option (alias: set) | |
# set-window-option (alias: setw) | |
# bind-key (alias: bind) | |
# unbind-key (alias: unbind) | |
################################################## | |
# prefix | |
set -g prefix M-` | |
unbind C-b | |
# basic | |
setw -g mode-keys emacs | |
set -g status-keys emacs | |
set -g history-limit 5000 | |
set -g default-terminal screen-256color | |
set -g repeat-time 1000 | |
# mouse | |
set -g mouse on | |
# status | |
set -g base-index 1 | |
set -g status-bg colour235 | |
set -g status-fg colour244 | |
set -g status-right ' %H:%M ' | |
setw -g window-status-current-bg colour240 | |
setw -g window-status-current-fg colour250 | |
setw -g window-status-current-format " #I:#W " | |
setw -g window-status-format ' #[bg=colour235]#[fg=colour248]#I:#W#F ' | |
# command-line | |
setw -g message-bg black | |
setw -g message-fg colour9 | |
# copy/highlight/help mode | |
setw -g mode-fg colour0 | |
setw -g mode-bg colour248 | |
# pane | |
set -g pane-active-border-fg white | |
set -g pane-border-fg colour8 | |
# bindings | |
bind M-` last-window | |
bind -r ^ resize-pane -D | |
bind -r { resize-pane -L | |
bind -r } resize-pane -R | |
bind ( swap-pane -U | |
bind ) swap-pane -D | |
bind -n M-} next-window | |
bind -n M-{ previous-window | |
bind -n M-1 select-window -t :1 | |
bind -n M-2 select-window -t :2 | |
bind -n M-3 select-window -t :3 | |
bind -n M-4 select-window -t :4 | |
bind -n M-5 select-window -t :5 | |
bind 0 break-pane -d | |
bind 2 split-window -v | |
bind 3 split-window -h | |
bind . command-prompt "swap-window -t '%%'" | |
bind / command-prompt "split-window -h 'exec man %%'" | |
bind R source-file ~/.tmux.conf | |
bind k kill-pane | |
# access clipboard from tmux | |
bind C run-shell "tmux showb | ssh localhost pbcopy" | |
bind V run-shell "tmux setb \"`ssh localhost pbpaste`\"" | |
# Guide | |
# | |
# Show bindings | |
# list-keys | |
# (prefix) ? | |
# | |
# Show commands | |
# list-commands | |
# | |
# Command | |
# (prefix) : | |
# | |
# Split window horizontally, adding a pane | |
# split-window -h | |
# | |
# Split window vertically, adding a pane | |
# split-window -v | |
# | |
# Focus on next (other) pane | |
# select-pane -t :.+ | |
# (prefix) o | |
# | |
# Break out a pane, preserving it. Moves pane to new window. | |
# break-pane -d | |
# | |
# Kill a pane, destroying it. | |
# kill-pane | |
# | |
# Move a pane to another window (target) | |
# join-pane -t <TARGET_NUMBER> | |
# | |
# Swap (Rotate) panes clockwise | |
# swap-pane -D | |
# (prefix) ) | |
# | |
# Swap (Rotate) panes counter-clockwise | |
# { swap-pane -U | |
# (prefix) ( | |
# | |
# Last pane | |
# last-pane | |
# (prefix) ; | |
# | |
# Resize pane: Up | |
# resize-pane -U | |
# resize-pane -U 5 | |
# | |
# Resize pane: Down | |
# resize-pane -D | |
# (prefix) ^ | |
# resize-pane -D 5 | |
# | |
# Resize pane: Left | |
# resize-pane -L | |
# (prefix) { | |
# resize-pane -L 5 | |
# | |
# Resize pane: Right | |
# resize-pane -R | |
# (prefix) } | |
# resize-pane -R 5 | |
# | |
# Move window | |
# move-window -t <TARGET_NUMBER> | |
# move-window -s <SOURCE_NUMBTER> -t <TARGET_NUMBER> | |
# | |
# Swap window | |
# swap-window -t <TARGET_NUMBER> | |
# | |
# Layout: Even Horizontal | |
# select-layout even-horizontal | |
# M-1 | |
# | |
# Layout: Even Vertical | |
# select-layout even-vertical | |
# M-2 | |
# | |
# Layout: Main Horizontal | |
# select-layout main-horizontal | |
# M-3 | |
# | |
# Layout: Main Vertical | |
# select-layout main-vertical | |
# M-4 | |
# | |
# Layout: Main Tiled | |
# select-layout tiled | |
# M-5 | |
# | |
# bind-key (alias: bind) | |
# * The `-r` flag indicates this key may repeat, see the | |
# `repeat-time` option. | |
# * `-n` is an alias for `-T root`. | |
# * `-T <key-table>` | |
# | |
# Print Tmux Colors | |
# for i in {0..255}; do | |
# printf "\x1b[38;5;${i}mcolour${i}\x1b[0m\n" | |
# done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment