Created
October 11, 2022 04:04
-
-
Save HanggiAnggono/9fdb64d9cd733418116641c66685f217 to your computer and use it in GitHub Desktop.
tmux and alacritty config
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
cursor: | |
style: | |
shape: Beam | |
blinking: Always | |
blinking_interval: 500 | |
vi_mode_style: | |
shape: Block | |
selection: | |
# This string contains all characters that are used as separators for | |
# "semantic words" in Alacritty. | |
semantic_escape_chars: ",│`|:\"' ()[]{}<>\t" | |
# When true, selected text will be copied to the primary clipboard | |
save_to_clipboard: true | |
# Login shell with arguments | |
shell: | |
program: /bin/zsh | |
args: | |
- --login | |
key_bindings: | |
- { key: Left, mods: Alt, chars: "\x1bb" } # Skip word left | |
- { key: Right, mods: Alt, chars: "\x1bf" } # Skip word right | |
- { key: Left, mods: Command, chars: "\x1bOH", mode: AppCursor } # Home | |
- { key: Right, mods: Command, chars: "\x1bOF", mode: AppCursor } # End | |
- { key: Back, mods: Command, chars: "\x15" } # Delete line | |
- { key: Back, mods: Alt, chars: "\x1b\x7f" } # Delete word |
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
set-window-option -g status-position top | |
set -g prefix C-Space | |
set -g mouse on | |
set -g base-index 1 | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
# THEME | |
set -g status-bg blue | |
set -g status-fg black | |
setw -g window-status-current-style 'fg=blue bg=black bold' | |
set -g window-status-format '#I:#(pwd="#{pane_current_path}"; echo ${pwd####*/})#F ' | |
set -g window-status-current-format '#I:#(pwd="#{pane_current_path}"; echo ${pwd####*/})#F' | |
# status bar updates every 15s by default**, change to 1s here | |
# (this step is optional - a lower latency might have negative battery/cpu usage impacts) | |
set -g status-interval 5 | |
set -g history-limit 5000 | |
#set inactive/active window styles | |
set -g window-style 'fg=colour247,bg=colour236' | |
set -g window-active-style 'fg=colour250,bg=black' | |
# set the pane border colors | |
set -g pane-border-style 'fg=colour235,bg=colour238' | |
set -g pane-active-border-style 'fg=colour51,bg=colour236' | |
# BINDINGS | |
# Use Shift up or down keys without prefix key to switch windows | |
# use shift left or right to switch panes | |
bind -n S-Up previous-window | |
bind -n S-Down next-window | |
bind -n S-Left select-pane -L | |
bind -n S-Right select-pane -R | |
# kill pane without confirm | |
bind-key x kill-pane | |
# split pane with \\ or | | |
bind -n C-d split-window -h -c "#{pane_current_path}" | |
#bind-key S-d split-window -v | |
# Alt arrow to move between words | |
# configured in alacritty | |
# Reload tmux config | |
bind r source-file ~/.tmux.conf | |
# Search with Ctrl + Alt + f | |
bind -n C-M-f copy-mode \; command-prompt -i -p "(search down)" "send -X search-forward-incremental \"%%%\"" | |
# Easily clear history and simulate iTerm ctrl-k function | |
bind -n C-k send-keys -R C-l \; clear-history | |
bind C-k send-keys C-k # pass through for C-k |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment