Last active
January 15, 2025 17:01
-
-
Save kukat/9523ada2a8248e76eb5595e6a6b7d976 to your computer and use it in GitHub Desktop.
ghostty
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
command = /bin/zsh -c "tmux new -A -s work" | |
theme = catppuccin-mocha | |
adjust-cell-height = 15% | |
mouse-hide-while-typing = true | |
macos-non-native-fullscreen=visible-menu | |
macos-titlebar-style = hidden | |
macos-option-as-alt = true | |
window-decoration = false | |
# To delete from the current position to the start of the line | |
keybind = super+backspace=esc:w | |
### tmux integration | |
# switch window | |
keybind = super+one=text:\x01\x31 | |
keybind = super+two=text:\x01\x32 | |
keybind = super+three=text:\x01\x33 | |
keybind = super+four=text:\x01\x34 | |
keybind = super+five=text:\x01\x35 | |
keybind = super+six=text:\x01\x36 | |
keybind = super+seven=text:\x01\x37 | |
keybind = super+eight=text:\x01\x38 | |
keybind = super+nine=text:\x01\x39 | |
# create new window Ctrl+a+c | |
keybind = super+t=text:\x01\x63 | |
# Rename a tmux window on Cmd+r in tmux it is Ctrl+b+, | |
keybind = super+r=text:\x01\x2c | |
# Switch to a window using tmux-fzf on Cmd+p in tmux it is Ctrl+b+w | |
keybind = super+p=text:\x01\x77 | |
# switch session | |
keybind = super+k=text:\x01\x73 |
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 terminal colors | |
set-option -sa terminal-overrides ",xterm*:Tc" | |
# Enable mouse support | |
set -g mouse on | |
# Start windows and panes at 1, not 0 | |
set -g base-index 1 | |
set -g pane-base-index 1 | |
set-window-option -g pane-base-index 1 | |
set-option -g renumber-windows on | |
# kill pane | |
bind-key x kill-pane | |
# Pane resizing | |
bind -n M-h resize-pane -L | |
bind -n M-l resize-pane -R | |
bind -n M-k resize-pane -U | |
bind -n M-j resize-pane -D | |
# Move window to the left | |
bind -n M-i swap-window -t -1 | |
# Move window to the right | |
bind -n M-o swap-window -t +1 | |
# Set vi mode | |
set-window-option -g mode-keys vi | |
# replace C-b by C-a instead of using both prefixes | |
set -gu prefix2 | |
unbind C-a | |
unbind C-b | |
set -g prefix C-a | |
bind C-a send-prefix | |
# create session | |
bind C-c new-session | |
# Use visual selection mode as vi | |
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 | |
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel | |
# Save and restore session | |
set -g @resurrect-save 'S' | |
set -g @resurrect-restore 'R' | |
# Tmux theme | |
set -g @catppuccin_flavour 'mocha' | |
set -g @catppuccin_right_separator "█" | |
TMUX_FZF_ORDER="session|window|pane|command|keybinding" | |
TMUX_FZF_OPTIONS="-p -w 90% -h 70% -m" | |
# more options here: https://github.com/sainnhe/tmux-fzf/issues/6#issuecomment-578750879 | |
bind f run-shell -b " ~/.tmux/plugins/tmux-fzf/scripts/window.sh switch" | |
# Plugins | |
set -g @plugin 'tmux-plugins/tpm' | |
set -g @plugin 'tmux-plugins/tmux-sensible' | |
set -g @plugin 'sainnhe/tmux-fzf' | |
set -g @plugin 'christoomey/vim-tmux-navigator' | |
set -g @plugin 'dreamsofcode-io/catppuccin-tmux' | |
set -g @plugin 'tmux-plugins/tmux-resurrect' | |
set -g @plugin 'tmux-plugins/tmux-continuum' | |
set -g @resurrect-strategy-nvim 'session' | |
set-option -g default-command "reattach-to-user-namespace -l zsh" | |
run '~/.tmux/plugins/tpm/tpm' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment