Skip to content

Instantly share code, notes, and snippets.

@darrylhebbes
Last active February 12, 2022 18:46
Show Gist options
  • Save darrylhebbes/83510761e6f818de620823360a0777ec to your computer and use it in GitHub Desktop.
Save darrylhebbes/83510761e6f818de620823360a0777ec to your computer and use it in GitHub Desktop.
Configs
env:
TERM: xterm-256color
WINIT_X11_SCALE_FACTOR: "1.0"
custom_cursor_colors: true
cursor:
style: Block
unfocused_hollow: true
bell:
animation: EaseOutExpo
duration: 0
mouse_bindings:
- { mouse: Middle, action: PasteSelection }
mouse:
double_click: { threshold: 300 }
triple_click: { threshold: 300 }
faux_scrollback_lines: 1
selection:
semantic_escape_chars: ",│`|:\"' ()[]{}<>"
live_config_reload: true
font:
normal:
family: 'Hack Nerd Font Mono'
style: Regular
bold:
family: 'Hack Nerd Font Mono'
style: Bold
italic:
family: 'Hack Nerd Font Mono'
style: Italic
size: 12.0
use_thin_strokes: true
window:
opacity: 1.0
dimensions:
columns: 160
lines: 48
padding:
x: 5
y: 5
scrolling:
history: 10000
multiplier: 3
shell:
program: /usr/local/bin/fish
args:
- --login
# https://github.com/alacritty/alacritty/issues/62#issuecomment-347552058
key_bindings:
- { key: X, mods: Alt, chars: "\x1bx" } # Alt - X fixes Emacs MetaX
- { key: Grave, mods: Alt, chars: "\x1b`" } # Alt + `
- { key: Grave, mods: Alt|Shift, chars: "\x1b~" } # Alt + ~
- { key: Space, mods: Control, chars: "\x00" } # Ctrl + Space
- { key: Grave, mods: Alt, chars: "\x1b`" } # Alt + `
- { key: Grave, mods: Alt|Shift, chars: "\x1b~" } # Alt + ~
- { key: Period, mods: Alt, chars: "\x1b." } # Alt + .
- { key: Key8, mods: Alt|Shift, chars: "\x1b*" } # Alt + *
- { key: Key3, mods: Alt|Shift, chars: "\x1b#" } # Alt + #
- { key: Period, mods: Alt|Shift, chars: "\x1b>" } # Alt + >
- { key: Comma, mods: Alt|Shift, chars: "\x1b<" } # Alt + <
- { key: Minus, mods: Alt|Shift, chars: "\x1b_" } # Alt + _
- { key: Key5, mods: Alt|Shift, chars: "\x1b%" } # Alt + %
- { key: Key6, mods: Alt|Shift, chars: "\x1b^" } # Alt + ^
- { key: Backslash, mods: Alt, chars: "\x1b\\"} # Alt + \
- { key: Backslash, mods: Alt|Shift, chars: "\x1b|" } # Alt + |
schemes:
kitty: &kitty
# Default colors
primary:
background: '#000000'
foreground: '#dddddd'
# Normal colors
normal:
black: '#000000'
red: '#cc0403'
green: '#19cb00'
yellow: '#cecb00'
blue: '#0d73cc'
magenta: '#cb1ed1'
cyan: '#0dcdcd'
white: '#dddddd'
# Bright colors
bright:
black: '#767676'
red: '#f2201f'
green: '#23fd00'
yellow: '#fffd00'
blue: '#1a8fff'
magenta: '#fd28ff'
cyan: '#14ffff'
white: '#ffffff'
visual_studio: &vstudio
# Default colors
primary:
background: '#1e1e1e' #Background from Dark Theme
foreground: '#cccccc'
# Selection colors
selection:
text: CellForeground
background: '#565656'
# Normal colors
normal:
black: '#000000'
red: '#cd3131'
green: '#0dbc79'
yellow: '#e5e510'
blue: '#2472c8'
magenta: '#bc3fbc'
cyan: '#11a8cd'
white: '#e5e5e5'
# Bright colors
bright:
black: '#666666'
red: '#f14c4c'
green: '#23d18b'
yellow: '#f5f543'
blue: '#3b8eea'
magenta: '#d670d6'
cyan: '#29b8db'
white: '#e5e5e5'
# Colors (Iceberg Dark) https://github.com/alacritty/alacritty/wiki/Color-schemes#iceberg
iceberg: &iceberg
# Default colors
primary:
background: '#161821'
foreground: '#d2d4de'
# Normal colors
normal:
black: '#161821'
red: '#e27878'
green: '#b4be82'
yellow: '#e2a478'
blue: '#84a0c6'
magenta: '#a093c7'
cyan: '#89b8c2'
white: '#c6c8d1'
# Bright colors
bright:
black: '#6b7089'
red: '#e98989'
green: '#c0ca8e'
yellow: '#e9b189'
blue: '#91acd1'
magenta: '#ada0d3'
cyan: '#95c4ce'
white: '#d2d4de'
colors: *iceberg
# Only edit in dotfiles.org. Last edit: nil
# Source : https://github.com/gcmt/dotfiles/blob/master/tmux/tmux.conf
# Source : https://github.com/raxod502/radian/blob/develop/tmux/.tmux.conf
set -s escape-time 0
set -s focus-events on
set -s set-clipboard off
set -s default-terminal "xterm-256color"
set -ag terminal-overrides ',screen*:cvvis=\E[34l\E[?25h'
set -g mouse on
set -g history-limit 10000
setw -g aggressive-resize on
set -g renumber-windows on
setw -g automatic-rename on
set -g base-index 1
setw -g pane-base-index 1
set -g set-titles on
set -g set-titles-string '#S - Tmux'
set -g bell-action none
set -g visual-bell off
set -g visual-activity off
setw -g monitor-activity off
# Windows
#set -g status-position top
# Modes
setw -g mode-keys vi
setw -g status-keys emacs
unbind C-b
set -g prefix C-a
bind C-a send-prefix
## Reload tmux config
unbind r
bind r source-file ~/.tmux.conf \; display "Reloaded ~/.tmux.conf"
# don't exit copy mode when mouse is released
unbind -T copy-mode-vi MouseDragEnd1Pane
# Use Alt-arrow keys without prefix key to switch panes
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
# Movement between windows
bind -n S-Right next-window
bind -n S-Left previous-window
# Panes
unbind '"'
# don't rename windows automatically
set-option -g allow-rename off
# Newly created panes have the PWD of the previously selected pane
bind '-' split-window -v -c "#{pane_current_path}" # Split panes horizontal
bind '_' split-window -v -c "#{pane_current_path}" # Split panes horizontal
bind '%' split-window -h -c "#{pane_current_path}" # Split panes vertically
bind '|' split-window -h -c "#{pane_current_path}" # Split panes vertically
bind q killp
# vi-like copy mode
# bind -T copy-mode-vi / command-prompt -p "search-forward:" "send -X search-forward \"%%%\""
# bind -T copy-mode-vi ? command-prompt -p "search-backward:" "send -X search-backward \"%%%\""
# Select For Copy
bind-key -T copy-mode-vi C-c send-keys -X clear-selection
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
# Copy & Paste, Vi Style
# bind-key -T copy-mode-vi y send-keys -X copy-pipe 'xclip -sel clip' \; display ' copied to system clipboard'
bind-key -T copy-mode-vi y send-keys -X copy-pipe "pbcopy" \; display ' copied to system clipboard'
bind-key -T copy-mode-vi r send-keys -X rectangle-toggle
bind-key ` last-window
# Theme related : https://github.com/egel/tmux-gruvbox/blob/master/tmux-gruvbox-dark.conf
set-option -g status "on"
# default statusbar color
set-option -g status-style bg=colour237,fg=colour223 # bg=bg1, fg=fg1
# default window title colors
set-window-option -g window-status-style bg=colour214,fg=colour237 # bg=yellow, fg=bg1
# default window with an activity alert
set-window-option -g window-status-activity-style bg=colour237,fg=colour248 # bg=bg1, fg=fg3
# active window title colors
set-window-option -g window-status-current-style bg=red,fg=colour237 # fg=bg1
# pane border
set-option -g pane-active-border-style fg=colour250 #fg2
set-option -g pane-border-style fg=colour237 #bg1
# message infos
set-option -g message-style bg=colour239,fg=colour223 # bg=bg2, fg=fg1
# writing commands inactive
set-option -g message-command-style bg=colour239,fg=colour223 # bg=fg3, fg=bg1
# pane number display
set-option -g display-panes-active-colour colour250 #fg2
set-option -g display-panes-colour colour237 #bg1
# clock
set-window-option -g clock-mode-colour colour109 #blue
# bell
set-window-option -g window-status-bell-style bg=colour167,fg=colour235 # bg=red, fg=bg
## Theme settings mixed with colors (unfortunately, but there is no cleaner way)
set-option -g status-justify "left"
set-option -g status-left-style none
set-option -g status-left-length "80"
set-option -g status-right-style none
set-option -g status-right-length "80"
set-window-option -g window-status-separator ""
set-option -g status-left "#[bg=colour241,fg=colour248] #S #[bg=colour237,fg=colour241,nobold,noitalics,nounderscore]"
set-option -g status-right "#[bg=colour237,fg=colour239 nobold, nounderscore, noitalics]#[bg=colour239,fg=colour246] %Y-%m-%d  %H:%M #[bg=colour239,fg=colour248,nobold,noitalics,nounderscore]#[bg=colour248,fg=colour237] #h "
set-window-option -g window-status-current-format "#[bg=colour214,fg=colour237,nobold,noitalics,nounderscore]#[bg=colour214,fg=colour239] #I #[bg=colour214,fg=colour239,bold] #W#{?window_zoomed_flag,*Z,} #[bg=colour237,fg=colour214,nobold,noitalics,nounderscore]"
set-window-option -g window-status-format "#[bg=colour239,fg=colour237,noitalics]#[bg=colour239,fg=colour223] #I #[bg=colour239,fg=colour223] #W #[bg=colour237,fg=colour239,noitalics]"
# vim: set ft=tmux tw=0 nowrap:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment