├── atuin ├── themes │ ├── catppuccin-macchiato-blue.toml │ ├── catppuccin-macchiato-green.toml │ ├── catppuccin-macchiato-mauve.toml │ └── catppuccin-macchiato-pink.toml ├── README.md └── config.toml ├── zellij ├── layouts │ ├── default.kdl │ ├── custom.kdl │ └── dev.kdl ├── zellij-sessionizer.sh ├── themes │ └── catppuccin.kdl ├── README.md └── config.kdl ├── .gitignore ├── ghostty ├── switch-theme.sh ├── config └── README.md ├── sync-from-system.sh ├── karabiner ├── README.md └── karabiner.edn ├── install.sh ├── README.md └── .zshrc /atuin/themes/catppuccin-macchiato-blue.toml: -------------------------------------------------------------------------------- 1 | [theme] 2 | name = "catppuccin-macchiato-blue" 3 | 4 | [colors] 5 | AlertInfo = "#a6da95" 6 | AlertWarn = "#f5a97f" 7 | AlertError = "#ed8796" 8 | Annotation = "#8aadf4" 9 | Base = "#cad3f5" 10 | Guidance = "#939ab7" 11 | Important = "#ed8796" 12 | Title = "#8aadf4" -------------------------------------------------------------------------------- /atuin/themes/catppuccin-macchiato-green.toml: -------------------------------------------------------------------------------- 1 | [theme] 2 | name = "catppuccin-macchiato-green" 3 | 4 | [colors] 5 | AlertInfo = "#a6da95" 6 | AlertWarn = "#f5a97f" 7 | AlertError = "#ed8796" 8 | Annotation = "#a6da95" 9 | Base = "#cad3f5" 10 | Guidance = "#939ab7" 11 | Important = "#ed8796" 12 | Title = "#a6da95" -------------------------------------------------------------------------------- /atuin/themes/catppuccin-macchiato-mauve.toml: -------------------------------------------------------------------------------- 1 | [theme] 2 | name = "catppuccin-macchiato-mauve" 3 | 4 | [colors] 5 | AlertInfo = "#a6da95" 6 | AlertWarn = "#f5a97f" 7 | AlertError = "#ed8796" 8 | Annotation = "#c6a0f6" 9 | Base = "#cad3f5" 10 | Guidance = "#939ab7" 11 | Important = "#ed8796" 12 | Title = "#c6a0f6" -------------------------------------------------------------------------------- /atuin/themes/catppuccin-macchiato-pink.toml: -------------------------------------------------------------------------------- 1 | [theme] 2 | name = "catppuccin-macchiato-pink" 3 | 4 | [colors] 5 | AlertInfo = "#a6da95" 6 | AlertWarn = "#f5a97f" 7 | AlertError = "#ed8796" 8 | Annotation = "#f5bde6" 9 | Base = "#cad3f5" 10 | Guidance = "#939ab7" 11 | Important = "#ed8796" 12 | Title = "#f5bde6" -------------------------------------------------------------------------------- /zellij/layouts/default.kdl: -------------------------------------------------------------------------------- 1 | layout { 2 | default_tab_template { 3 | pane size=1 borderless=true { 4 | plugin location="zellij:tab-bar" 5 | } 6 | children 7 | pane size=2 borderless=true { 8 | plugin location="zellij:status-bar" 9 | } 10 | } 11 | 12 | tab name="main" focus=true { 13 | pane 14 | } 15 | } -------------------------------------------------------------------------------- /zellij/layouts/custom.kdl: -------------------------------------------------------------------------------- 1 | layout { 2 | default_tab_template { 3 | children 4 | pane size=1 borderless=true { 5 | plugin location="zellij:compact-bar" 6 | } 7 | pane size=2 borderless=true { 8 | plugin location="zellij:status-bar" 9 | plugin location="zellij:datetime" 10 | plugin location="zellij:mem" 11 | } 12 | } 13 | 14 | tab name="main" focus=true { 15 | pane 16 | } 17 | 18 | tab name="dev" { 19 | pane split_direction="vertical" { 20 | pane 21 | pane 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /zellij/layouts/dev.kdl: -------------------------------------------------------------------------------- 1 | layout { 2 | default_tab_template { 3 | pane size=1 borderless=true { 4 | plugin location="zellij:tab-bar" 5 | } 6 | children 7 | pane size=2 borderless=true { 8 | plugin location="zellij:status-bar" 9 | } 10 | } 11 | 12 | tab name="code" focus=true { 13 | pane split_direction="vertical" { 14 | pane size="70%" name="editor" 15 | pane split_direction="horizontal" size="30%" { 16 | pane size="50%" name="terminal" 17 | pane size="50%" name="logs" 18 | } 19 | } 20 | } 21 | 22 | tab name="git" { 23 | pane name="git" 24 | } 25 | 26 | tab name="server" { 27 | pane name="server" 28 | } 29 | } -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # macOS 2 | .DS_Store 3 | .AppleDouble 4 | .LSOverride 5 | Icon 6 | ._* 7 | .DocumentRevisions-V100 8 | .fseventsd 9 | .Spotlight-V100 10 | .TemporaryItems 11 | .Trashes 12 | .VolumeIcon.icns 13 | .com.apple.timemachine.donotpresent 14 | .AppleDB 15 | .AppleDesktop 16 | Network Trash Folder 17 | Temporary Items 18 | .apdisk 19 | 20 | # Vim 21 | *.swp 22 | *.swo 23 | *~ 24 | .netrwhist 25 | 26 | # Zsh 27 | *.zwc 28 | .zcompdump* 29 | .zsh_history 30 | .zsh_sessions 31 | 32 | # Local overrides 33 | *.local 34 | .env 35 | 36 | # Backup files 37 | *.backup 38 | *.bak 39 | *.orig 40 | 41 | # Log files 42 | *.log 43 | 44 | # Temporary files 45 | *.tmp 46 | *.temp 47 | 48 | # Cache directories 49 | .cache/ 50 | 51 | # IDE specific 52 | .idea/ 53 | .vscode/ 54 | *.sublime-* 55 | 56 | # OS generated files 57 | Thumbs.db 58 | -------------------------------------------------------------------------------- /zellij/zellij-sessionizer.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Zellij sessionizer - quickly switch between projects 4 | # Inspired by ThePrimeagen's tmux-sessionizer 5 | 6 | if [[ $# -eq 1 ]]; then 7 | selected=$1 8 | else 9 | # Find directories in common project locations 10 | selected=$(find ~/Code ~/Desktop -mindepth 1 -maxdepth 2 -type d 2>/dev/null | \ 11 | grep -v node_modules | \ 12 | grep -v .git | \ 13 | fzf --preview 'ls -la {}' --preview-window=right:50%:wrap) 14 | fi 15 | 16 | if [[ -z $selected ]]; then 17 | exit 0 18 | fi 19 | 20 | selected_name=$(basename "$selected" | tr . _) 21 | zellij_running=$(pgrep -x zellij) 22 | 23 | if [[ -z $ZELLIJ ]]; then 24 | # Not in Zellij 25 | cd "$selected" && zellij attach "$selected_name" || zellij --session "$selected_name" --layout default 26 | else 27 | # Inside Zellij 28 | if ! zellij list-sessions | grep -q "^$selected_name"; then 29 | cd "$selected" && zellij --session "$selected_name" --layout default 30 | else 31 | echo "Session $selected_name already exists" 32 | fi 33 | fi -------------------------------------------------------------------------------- /ghostty/switch-theme.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Ghostty Catppuccin theme switcher 4 | CONFIG_FILE="$HOME/Library/Application Support/com.mitchellh.ghostty/config" 5 | 6 | echo "🎨 Catppuccin themes for Ghostty:" 7 | echo "" 8 | echo "1. Latte (Light)" 9 | echo "2. Frappé (Medium Light)" 10 | echo "3. Macchiato (Medium Dark) - Current" 11 | echo "4. Mocha (Dark)" 12 | echo "" 13 | 14 | read -p "Select theme (1-4): " choice 15 | 16 | case $choice in 17 | 1) 18 | theme="catppuccin-latte" 19 | icon="glass" 20 | bg_color="#eff1f5" 21 | ;; 22 | 2) 23 | theme="catppuccin-frappe" 24 | icon="blueprint" 25 | bg_color="#303446" 26 | ;; 27 | 3) 28 | theme="catppuccin-macchiato" 29 | icon="official" 30 | bg_color="#24273a" 31 | ;; 32 | 4) 33 | theme="catppuccin-mocha" 34 | icon="microchip" 35 | bg_color="#1e1e2e" 36 | ;; 37 | *) 38 | echo "❌ Invalid selection" 39 | exit 1 40 | ;; 41 | esac 42 | 43 | # Update theme 44 | sed -i '' "s/^theme = .*/theme = $theme/" "$CONFIG_FILE" 45 | sed -i '' "s/^macos-icon = .*/macos-icon = $icon/" "$CONFIG_FILE" 46 | sed -i '' "s/^unfocused-split-fill = .*/unfocused-split-fill = $bg_color/" "$CONFIG_FILE" 47 | 48 | echo "" 49 | echo "✅ Theme switched to: $theme" 50 | echo "🔄 Reload Ghostty config with Cmd+R or restart Ghostty" -------------------------------------------------------------------------------- /zellij/themes/catppuccin.kdl: -------------------------------------------------------------------------------- 1 | themes { 2 | catppuccin-latte { 3 | bg "#acb0be" // Surface2 4 | fg "#4c4f69" // Text 5 | red "#d20f39" 6 | green "#40a02b" 7 | blue "#1e66f5" 8 | yellow "#df8e1d" 9 | magenta "#ea76cb" // Pink 10 | orange "#fe640b" // Peach 11 | cyan "#04a5e5" // Sky 12 | black "#e6e9ef" // Mantle 13 | white "#4c4f69" // Text 14 | } 15 | 16 | catppuccin-frappe { 17 | bg "#626880" // Surface2 18 | fg "#c6d0f5" // Text 19 | red "#e78284" 20 | green "#a6d189" 21 | blue "#8caaee" 22 | yellow "#e5c890" 23 | magenta "#f4b8e4" // Pink 24 | orange "#ef9f76" // Peach 25 | cyan "#99d1db" // Sky 26 | black "#292c3c" // Mantle 27 | white "#c6d0f5" // Text 28 | } 29 | 30 | catppuccin-macchiato { 31 | bg "#5b6078" // Surface2 32 | fg "#cad3f5" // Text 33 | red "#ed8796" 34 | green "#a6da95" 35 | blue "#8aadf4" 36 | yellow "#eed49f" 37 | magenta "#f5bde6" // Pink 38 | orange "#f5a97f" // Peach 39 | cyan "#91d7e3" // Sky 40 | black "#1e2030" // Mantle 41 | white "#cad3f5" // Text 42 | } 43 | 44 | catppuccin-mocha { 45 | bg "#585b70" // Surface2 46 | fg "#cdd6f4" // Text 47 | red "#f38ba8" 48 | green "#a6e3a1" 49 | blue "#89b4fa" 50 | yellow "#f9e2af" 51 | magenta "#f5c2e7" // Pink 52 | orange "#fab387" // Peach 53 | cyan "#89dceb" // Sky 54 | black "#181825" // Mantle 55 | white "#cdd6f4" // Text 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /sync-from-system.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Sync configs FROM system TO dotfiles repo 4 | # This pulls any changes you've made locally back into the repo 5 | 6 | set -e 7 | 8 | echo "📥 Syncing configs from system to dotfiles repo..." 9 | echo "" 10 | 11 | # Colors 12 | GREEN='\033[0;32m' 13 | BLUE='\033[0;34m' 14 | YELLOW='\033[1;33m' 15 | NC='\033[0m' 16 | 17 | # Function to sync a file/directory 18 | sync_config() { 19 | local source="$1" 20 | local dest="$2" 21 | local name="$3" 22 | 23 | if [ -e "$source" ]; then 24 | if [ -d "$source" ]; then 25 | rsync -av --delete "$source/" "$dest/" 26 | else 27 | cp "$source" "$dest" 28 | fi 29 | echo -e "${GREEN} ✓ Synced $name${NC}" 30 | else 31 | echo -e "${YELLOW} ⚠ Skipped $name (not found)${NC}" 32 | fi 33 | } 34 | 35 | # Zsh 36 | echo -e "${BLUE}Syncing Zsh...${NC}" 37 | sync_config ~/.zshrc .zshrc "zshrc" 38 | 39 | # Zellij 40 | echo -e "${BLUE}Syncing Zellij...${NC}" 41 | sync_config ~/.config/zellij/config.kdl zellij/config.kdl "config" 42 | sync_config ~/.config/zellij/themes zellij/themes "themes" 43 | sync_config ~/.config/zellij/layouts zellij/layouts "layouts" 44 | sync_config ~/.config/zellij/zellij-sessionizer.sh zellij/zellij-sessionizer.sh "sessionizer" 45 | sync_config ~/.config/zellij/README.md zellij/README.md "README" 46 | 47 | # Atuin 48 | echo -e "${BLUE}Syncing Atuin...${NC}" 49 | sync_config ~/.config/atuin/config.toml atuin/config.toml "config" 50 | sync_config ~/.config/atuin/themes atuin/themes "themes" 51 | sync_config ~/.config/atuin/README.md atuin/README.md "README" 52 | 53 | # Ghostty 54 | echo -e "${BLUE}Syncing Ghostty...${NC}" 55 | sync_config "$HOME/Library/Application Support/com.mitchellh.ghostty/config" ghostty/config "config" 56 | sync_config "$HOME/Library/Application Support/com.mitchellh.ghostty/switch-theme.sh" ghostty/switch-theme.sh "theme switcher" 57 | sync_config "$HOME/Library/Application Support/com.mitchellh.ghostty/README.md" ghostty/README.md "README" 58 | 59 | # Karabiner 60 | echo -e "${BLUE}Syncing Karabiner...${NC}" 61 | sync_config ~/.config/karabiner.edn karabiner/karabiner.edn "config" 62 | sync_config ~/.config/karabiner/README.md karabiner/README.md "README" 2>/dev/null || true 63 | 64 | echo "" 65 | echo -e "${GREEN}✨ Sync complete!${NC}" 66 | echo "" 67 | echo "Review changes with: git status" 68 | echo "Commit changes with: git add -A && git commit -m 'Update configs from system'" -------------------------------------------------------------------------------- /ghostty/config: -------------------------------------------------------------------------------- 1 | # Font & Typography 2 | font-family = Dank Mono 3 | font-size = 20 4 | font-thicken = true 5 | adjust-cell-height = 2 6 | adjust-underline-position = 40% 7 | adjust-underline-thickness = -60% 8 | 9 | # Theme & Colors 10 | macos-icon = official 11 | theme = catppuccin-macchiato 12 | unfocused-split-opacity = 0.93 13 | unfocused-split-fill = #24273a 14 | selection-foreground = #cad3f5 15 | selection-background = #5b6078 16 | 17 | # Window Appearance 18 | window-width = 140 19 | window-height = 35 20 | window-padding-x = 20 21 | window-padding-y = 15 22 | window-padding-balance = true 23 | background-opacity = 0.97 24 | background-blur-radius = 25 25 | macos-titlebar-style = transparent 26 | macos-titlebar-proxy-icon = hidden 27 | 28 | # Cursor 29 | cursor-style = block 30 | cursor-style-blink = false 31 | cursor-opacity = 1.0 32 | 33 | # Behavior & Integration 34 | shell-integration = zsh 35 | window-save-state = always 36 | mouse-hide-while-typing = true 37 | copy-on-select = clipboard 38 | confirm-close-surface = false 39 | clipboard-paste-protection = false 40 | clipboard-read = allow 41 | clipboard-write = allow 42 | shell-integration-features = cursor,sudo,title 43 | 44 | # Performance & Scrollback 45 | scrollback-limit = 1000000 46 | link-url = true 47 | gtk-single-instance = true 48 | 49 | # Split Navigation Keybinds 50 | keybind = ctrl+h=goto_split:left 51 | keybind = ctrl+j=goto_split:bottom 52 | keybind = ctrl+k=goto_split:top 53 | keybind = ctrl+l=goto_split:right 54 | 55 | # Tab Navigation Keybinds 56 | keybind = cmd+h=previous_tab 57 | keybind = cmd+l=next_tab 58 | 59 | # Split Resizing Keybinds 60 | keybind = cmd+/=new_split:auto 61 | keybind = super+ctrl+h=resize_split:left,10 62 | keybind = super+ctrl+j=resize_split:down,10 63 | keybind = super+ctrl+k=resize_split:up,10 64 | keybind = super+ctrl+l=resize_split:right,10 65 | 66 | # Additional Productivity Keybinds 67 | keybind = cmd+d=new_split:right 68 | keybind = cmd+shift+d=new_split:down 69 | keybind = cmd+w=close_surface 70 | keybind = cmd+t=new_tab 71 | keybind = cmd+shift+t=new_window 72 | keybind = shift+enter=text:\n 73 | 74 | # Quick Tab Switching (like Zellij) 75 | keybind = cmd+1=goto_tab:1 76 | keybind = cmd+2=goto_tab:2 77 | keybind = cmd+3=goto_tab:3 78 | keybind = cmd+4=goto_tab:4 79 | keybind = cmd+5=goto_tab:5 80 | keybind = cmd+6=goto_tab:6 81 | keybind = cmd+7=goto_tab:7 82 | keybind = cmd+8=goto_tab:8 83 | keybind = cmd+9=goto_tab:9 84 | 85 | # Zoom & Focus 86 | keybind = cmd+enter=toggle_split_zoom 87 | keybind = cmd+shift+f=toggle_fullscreen 88 | 89 | # Reload Config 90 | keybind = cmd+r=reload_config 91 | -------------------------------------------------------------------------------- /ghostty/README.md: -------------------------------------------------------------------------------- 1 | # Ghostty Cheatsheet 👻 2 | 3 | ## What is Ghostty? 4 | A fast, feature-rich terminal emulator written in Zig with native GPU acceleration. 5 | 6 | ## Current Theme 7 | **Catppuccin Macchiato** 🎨 (aligned with Atuin & Zellij) 8 | 9 | ## Essential Keybindings 10 | 11 | ### Tab Management 12 | | Key | Action | 13 | |-----|--------| 14 | | `Cmd+T` | New tab | 15 | | `Cmd+W` | Close tab | 16 | | `Cmd+H` | Previous tab | 17 | | `Cmd+L` | Next tab | 18 | | `Cmd+1-9` | Go to tab 1-9 | 19 | | `Cmd+Shift+T` | New window | 20 | 21 | ### Split Management 22 | | Key | Action | 23 | |-----|--------| 24 | | `Cmd+D` | Split right | 25 | | `Cmd+Shift+D` | Split down | 26 | | `Cmd+/` | Auto split | 27 | | `Ctrl+H/J/K/L` | Navigate splits | 28 | | `Cmd+Enter` | Toggle split zoom | 29 | | `Cmd+Ctrl+H/J/K/L` | Resize splits | 30 | 31 | ### Quick Actions 32 | | Key | Action | 33 | |-----|--------| 34 | | `Cmd+R` | Reload config | 35 | | `Cmd+Shift+F` | Toggle fullscreen | 36 | | `Shift+Enter` | Insert newline | 37 | 38 | ### Scrolling 39 | Use mouse/trackpad for scrolling. Ghostty has excellent native scrolling support with the 1M line buffer! 40 | 41 | ## Configuration 42 | 43 | ### Config Location 44 | ``` 45 | ~/Library/Application Support/com.mitchellh.ghostty/config 46 | ``` 47 | 48 | ### Key Settings 49 | 50 | #### Typography 51 | ``` 52 | font-family = Dank Mono 53 | font-size = 20 54 | font-thicken = true 55 | ``` 56 | 57 | #### Theme & Appearance 58 | ``` 59 | theme = catppuccin-macchiato 60 | background-opacity = 0.97 61 | background-blur-radius = 25 62 | macos-titlebar-style = transparent 63 | ``` 64 | 65 | #### Performance 66 | ``` 67 | scrollback-limit = 1000000 # 1 MILLION lines! 68 | shell-integration = zsh 69 | copy-on-select = clipboard 70 | ``` 71 | 72 | ## Tips & Tricks 73 | 74 | ### 1. Split Workflows 75 | - Use `Cmd+D` for side-by-side editor/terminal 76 | - `Cmd+Enter` to focus on one split temporarily 77 | - Navigate with vim keys: `Ctrl+H/J/K/L` 78 | 79 | ### 2. Tab Organization 80 | - Name tabs by context (project, server, etc.) 81 | - Use `Cmd+1-9` for quick switching 82 | - Keep consistent tab order across sessions 83 | 84 | ### 3. Integration with Zellij 85 | When using Ghostty with Zellij: 86 | - Ghostty handles window/tab management 87 | - Zellij handles session/pane management 88 | - Use Ghostty for GUI features, Zellij for persistence 89 | 90 | ### 4. Copy & Paste 91 | - Select text to auto-copy 92 | - `Cmd+V` to paste 93 | - No clipboard protection for smooth workflow 94 | 95 | ### 5. Performance Tuning 96 | - GPU accelerated rendering 97 | - **1 MILLION line scrollback buffer** 🚀 98 | - Optimized for Retina displays 99 | - ~100MB RAM per terminal (worth it!) 100 | 101 | ## Common Workflows 102 | 103 | ### Development Setup 104 | ``` 105 | 1. Cmd+T # New tab for project 106 | 2. Cmd+D # Split for terminal 107 | 3. Ctrl+L # Focus editor split 108 | 4. Cmd+Enter # Zoom when needed 109 | ``` 110 | 111 | ### Multi-Project 112 | ``` 113 | 1. Cmd+T # Tab per project 114 | 2. Cmd+1/2/3 # Quick switch 115 | 3. Cmd+Shift+T # New window for different context 116 | ``` 117 | 118 | ### Debugging 119 | ``` 120 | 1. Cmd+F # Search output 121 | 2. Cmd+Shift+H # Jump to top 122 | 3. Cmd+K # Clear for fresh start 123 | ``` 124 | 125 | ## Ghostty vs Other Terminals 126 | 127 | | Feature | Ghostty | iTerm2 | Alacritty | 128 | |---------|---------|--------|-----------| 129 | | GPU Rendering | ✅ Native | ❌ | ✅ | 130 | | Splits | ✅ Built-in | ✅ | ❌ | 131 | | Tabs | ✅ Native | ✅ | ❌ | 132 | | Config | ✅ Simple | ❌ Complex | ✅ | 133 | | Performance | 🚀 Fastest | 🐌 | 🚀 | 134 | | macOS Native | ✅ | ✅ | ❌ | 135 | 136 | ## Shell Integration 137 | 138 | Ghostty automatically integrates with: 139 | - **Cursor tracking** - Knows where cursor is 140 | - **Sudo detection** - Shows when in sudo 141 | - **Title updates** - Dynamic window titles 142 | - **OSC sequences** - Full support 143 | 144 | ## Troubleshooting 145 | 146 | ### Config Not Loading? 147 | ```bash 148 | ghostty +validate-config 149 | ``` 150 | 151 | ### Performance Issues? 152 | - Check GPU acceleration: `ghostty +show-config | grep gpu` 153 | - Reduce scrollback limit if needed 154 | - Disable transparency/blur 155 | 156 | ### Font Rendering? 157 | - Adjust `font-thicken` setting 158 | - Try different `adjust-cell-height` values 159 | - Check font installation 160 | 161 | ## Resources 162 | 163 | - [Ghostty Docs](https://ghostty.org/docs) 164 | - [Config Reference](https://ghostty.org/docs/config) 165 | - [Catppuccin Themes](https://github.com/catppuccin/ghostty) -------------------------------------------------------------------------------- /karabiner/README.md: -------------------------------------------------------------------------------- 1 | # Karabiner Cheatsheet 🎮 2 | 3 | ## What is Karabiner? 4 | Advanced keyboard customization for macOS. Your config uses Goku (EDN format) for cleaner configuration. 5 | 6 | ## Core Concepts 7 | - **Layers**: Modifier keys that change keyboard behavior 8 | - **Simlayers**: Keys that act as modifiers when held 9 | - **Modes**: Temporary keyboard states 10 | 11 | ## Key Layers 12 | 13 | ### Caps Lock → Escape/Control 14 | - **Tap**: Escape 15 | - **Hold**: Left Control 16 | - **Caps+A**: Actual Caps Lock 17 | 18 | ### Function Keys 19 | - **F23**: Special modifier 20 | - **F24**: Launch mode (alone = Option+Space) 21 | 22 | ## Simlayers (Hold Key) 23 | 24 | ### Home Row Modifiers 25 | | Key | Simlayer | Description | 26 | |-----|----------|-------------| 27 | | `-` | fn-mode | Control + arrows | 28 | | `A` | opt-mode | Option + arrows | 29 | | `S` | shift-opt-mode | Shift+Option + arrows | 30 | | `D` | shift-mode | Shift + arrows | 31 | | `F` | movement-mode | Arrow keys | 32 | | `G` | cursor-mode | Cursor manipulation | 33 | | `J` | delete-mode | Delete operations | 34 | | `K` | editor-mode | Editor navigation | 35 | 36 | ### Top Row 37 | | Key | Simlayer | Description | 38 | |-----|----------|-------------| 39 | | `Q` | quick-mode | Quick actions | 40 | | `W` | close-mode | Close operations | 41 | | `E` | finder-mode | Finder shortcuts | 42 | | `R` | peek-mode | Peek definitions | 43 | | `T` | go-mode | Go to navigation | 44 | | `P` | code-mode | Code actions | 45 | 46 | ### Bottom Row 47 | | Key | Simlayer | Description | 48 | |-----|----------|-------------| 49 | | `Z` | emoji-mode | Emoji picker | 50 | | `C` | command-mode | Command shortcuts | 51 | 52 | ## Essential Shortcuts 53 | 54 | ### Navigation (Movement Mode - Hold F) 55 | - `F+H/J/K/L` → Arrow keys 56 | - `F+Y` → Ctrl+Left (word left) 57 | - `F+O` → Ctrl+Right (word right) 58 | 59 | ### Selection (Shift Mode - Hold D) 60 | - `D+H/J/K/L` → Shift + arrows 61 | - `D+Y` → Select word left 62 | - `D+O` → Select word right 63 | 64 | ### Delete (Hold J) 65 | - `J+S` → Backspace 66 | - `J+D` → Delete forward 67 | - `J+A` → Option+Backspace (delete word) 68 | - `J+F` → Option+Delete (delete word forward) 69 | - `J+Escape` → Delete line (in VS Code) 70 | 71 | ### Go To (Hold T) 72 | - `T+O` → Go to definition 73 | - `T+I` → Go to implementation 74 | - `T+R` → Go to references 75 | - `T+S` → Go to symbol 76 | - `T+L` → Go to line 77 | 78 | ### Peek (Hold R) 79 | - `R+H` → Peek definition 80 | - `R+E` → Peek implementation 81 | - `R+N` → Peek references 82 | 83 | ### Editor (Hold K) 84 | - `K+A` → Previous editor tab 85 | - `K+T` → Next editor tab 86 | - `K+R` → Go back 87 | - `K+S` → Go forward 88 | 89 | ### Spacebar Magic (Hold Space) 90 | - `Space+A/S` → `[]` brackets 91 | - `Space+D/F` → `()` parentheses 92 | - `Space+J/K` → `{}` braces 93 | - `Space+L/;` → `<>` angle brackets 94 | - `Space+Q` → `()=> ` arrow function 95 | - `Space+'` → `=""` attribute 96 | 97 | ### Numbers (Hold Tab) 98 | - `Tab+A` → 1 99 | - `Tab+S` → 2 100 | - `Tab+D` → 3 101 | - ... through `Tab+;` → 0 102 | 103 | ### Special Characters (; or .) 104 | - `;/. + E` → `!` exclamation 105 | - `;/. + A` → `@` at 106 | - `;/. + H` → `#` hash 107 | - `;/. + D` → `$` dollar 108 | - `;/. + P` → `%` percent 109 | - `;/. + C` → `^` caret 110 | - `;/. + S` → `&` ampersand 111 | - `;/. + B` → `*` asterisk 112 | 113 | ### Emoji (Hold Z) 114 | - `Z+E` → Emoji picker 115 | - `Z+B` → 😊 blush 116 | - `Z+F` → 🔥 fire 117 | - `Z+H` → 😍 heart-eyes 118 | - `Z+J` → 😂 joking 119 | - `Z+L` → ❤️ love 120 | - `Z+M` → 🤯 mind blown 121 | - `Z+P` → 🎉 party 122 | 123 | ### Launch Apps (Hold L) 124 | - `L+C` → VS Code (via Alfred) 125 | - `L+D` → Discord 126 | - `L+F` → Finder 127 | - `L+G` → Google Chrome 128 | - `L+S` → Slack 129 | - `L+T` → iTerm 130 | - `L+K` → Restart Karabiner 131 | 132 | ### Escape Mode Shortcuts 133 | - `Esc+T` → Todo pad 134 | - `Esc+A` → App launcher 135 | - `Esc+C` → Auto center app 136 | - `Esc+N` → Journal 137 | - `Esc+W` → Wiki 138 | 139 | ## App-Specific 140 | 141 | ### VS Code 142 | - `Cmd` (tap) → Go to file 143 | - `Ctrl` (tap) → Command palette 144 | - `W+A` → Close all 145 | - `W+O` → Close others 146 | 147 | ### Chrome 148 | - `Cmd` (tap) → New tab (Ctrl+T) 149 | - `D` (with 2 fingers) → Dev tools 150 | 151 | ## Pro Tips 152 | 153 | 1. **Hyper Key**: Your config uses Command+Shift+Control+Option as "hyper" 154 | 2. **Escape Resets**: Pressing Escape clears all stuck modes 155 | 3. **Vim Navigation**: H/J/K/L work in most layer modes 156 | 4. **Context Aware**: Different apps have different shortcuts 157 | 158 | ## Troubleshooting 159 | 160 | ### Stuck Mode? 161 | Press `Escape` to reset all modes 162 | 163 | ### Restart Karabiner 164 | Press `L+K` (Launch mode + K) 165 | 166 | ### View Current Config 167 | The config is at `~/.config/karabiner.edn` -------------------------------------------------------------------------------- /zellij/README.md: -------------------------------------------------------------------------------- 1 | # Zellij Cheatsheet 🚀 2 | 3 | ## Core Concepts 4 | - **Session**: A Zellij workspace (like tmux session) 5 | - **Tab**: Collection of panes (like tmux window) 6 | - **Pane**: Terminal instance 7 | - **Mode**: Current input mode (Normal, Pane, Tab, etc.) 8 | 9 | ## Modes & Navigation 10 | 11 | | Mode | Enter | Purpose | 12 | |------|-------|---------| 13 | | Normal | Default | Regular terminal use | 14 | | Locked | `Ctrl+g` | Disable Zellij keys | 15 | | Pane | `Ctrl+p` | Pane management | 16 | | Tab | `Ctrl+t` | Tab management | 17 | | Resize | `Ctrl+n` | Resize panes | 18 | | Move | `Alt+m` | Move panes | 19 | | Scroll | `Alt+s` | Scroll buffer | 20 | | Session | `Ctrl+o` | Session management | 21 | 22 | **Exit any mode**: `Esc` (except Locked - use `Ctrl+g`) 23 | 24 | ## Essential Keybindings 25 | 26 | ### Global (from Normal mode) 27 | - `Ctrl+q` - Quit Zellij 28 | - `Alt+n` - New pane 29 | - `Alt+h/j/k/l` - Navigate panes (←↓↑→) 30 | - `Alt+[/]` - Previous/Next swap layout 31 | - `Alt+f` - Toggle floating panes 32 | - `Alt+1-9` - Go to tab 1-9 33 | - `Alt+w` - Close tab 34 | - `Alt+r` - Rename tab 35 | - `Alt+i/o` - Move tab left/right 36 | 37 | ### Pane Mode (`Ctrl+p`) 38 | - `n` - New pane 39 | - `d` - New pane down 40 | - `r` - New pane right 41 | - `x` - Close pane 42 | - `f` - Toggle fullscreen 43 | - `z` - Toggle pane frames 44 | - `w` - Toggle floating panes 45 | - `e` - Toggle embed/float 46 | - `c` - Rename pane 47 | - `h/j/k/l` - Navigate panes 48 | 49 | ### Tab Mode (`Ctrl+t`) 50 | - `n` - New tab 51 | - `x` - Close tab 52 | - `r` - Rename tab 53 | - `h/l` or `←/→` - Navigate tabs 54 | - `Tab` - Toggle last tab 55 | - `1-9` - Go to tab number 56 | - `s` - Sync tab input 57 | - `b` - Break pane to new tab 58 | - `[/]` - Break pane left/right 59 | 60 | ### Resize Mode (`Ctrl+n`) 61 | - `h/j/k/l` - Increase size in direction 62 | - `H/J/K/L` - Decrease size in direction 63 | - `+/=` - Increase size 64 | - `-` - Decrease size 65 | 66 | ### Scroll Mode (`Alt+s`) 67 | - `j/k` - Scroll down/up 68 | - `d/u` - Half page down/up 69 | - `Ctrl+f/b` - Page down/up 70 | - `s` - Enter search 71 | - `e` - Edit scrollback in $EDITOR 72 | 73 | ### Session Mode (`Ctrl+o`) 74 | - `d` - Detach session 75 | - `w` - Session manager 76 | - `p` - Plugin manager 77 | - `c` - Configuration 78 | 79 | ## Custom Aliases (from .zshrc) 80 | 81 | ```bash 82 | zj # Start Zellij 83 | zja # Attach to session 84 | zjl # List sessions 85 | zjk # Kill session 86 | zjka # Kill all sessions 87 | zjd # Start with dev layout 88 | zs # Session switcher 89 | Ctrl+f # Launch sessionizer 90 | ``` 91 | 92 | ## Layouts 93 | 94 | ### Default Layout 95 | - Single pane with tab/status bars 96 | 97 | ### Dev Layout (`zjd`) 98 | ``` 99 | ┌─────────────┬──────────┐ 100 | │ │ Terminal │ 101 | │ Editor ├──────────┤ 102 | │ (70%) │ Logs │ 103 | └─────────────┴──────────┘ 104 | [code] [git] [server] 105 | ``` 106 | 107 | ## Command Line 108 | 109 | ```bash 110 | # Sessions 111 | zellij # Start new session 112 | zellij --session name # Named session 113 | zellij attach name # Attach to session 114 | zellij list-sessions # List all sessions 115 | zellij kill-session name # Kill specific session 116 | zellij kill-all-sessions # Kill all sessions 117 | 118 | # Layouts 119 | zellij --layout default # Use default layout 120 | zellij --layout dev # Use dev layout 121 | zellij --layout /path/to/layout # Custom layout 122 | 123 | # Actions 124 | zellij action new-pane # Create new pane 125 | zellij action write "text" # Write to focused pane 126 | zellij action rename-tab "name" # Rename current tab 127 | 128 | # Config 129 | zellij setup --check # Check config 130 | zellij setup --dump-config # Show default config 131 | ``` 132 | 133 | ## Tips & Tricks 134 | 135 | 1. **Project Sessions**: Use sessionizer (`Ctrl+f`) to create per-project sessions 136 | 2. **Persistent Sessions**: Sessions survive disconnection (auto-serialized) 137 | 3. **Copy Mode**: In scroll mode, select text with mouse (copy-on-select enabled) 138 | 4. **Floating Panes**: `Alt+f` for temporary overlay panes 139 | 5. **Sync Input**: In tab mode, press `s` to type in all panes 140 | 6. **Quick Rename**: `Alt+r` to rename tabs on the fly 141 | 142 | ## Configuration Locations 143 | 144 | - Config: `~/.config/zellij/config.kdl` 145 | - Layouts: `~/.config/zellij/layouts/` 146 | - Themes: `~/.config/zellij/themes/` 147 | - Sessionizer: `~/.config/zellij/zellij-sessionizer.sh` 148 | 149 | ## Current Theme 150 | **Catppuccin Macchiato** 🎨 151 | 152 | Switch themes by editing `theme` in config.kdl: 153 | - `catppuccin-latte` (Light) 154 | - `catppuccin-frappe` (Medium) 155 | - `catppuccin-macchiato` (Current) 156 | - `catppuccin-mocha` (Dark) -------------------------------------------------------------------------------- /install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Install dotfiles - applies configs FROM repo TO system 4 | # Creates backups of existing configs before overwriting 5 | 6 | set -e 7 | 8 | echo "🚀 Installing dotfiles..." 9 | echo "" 10 | 11 | # Colors 12 | GREEN='\033[0;32m' 13 | BLUE='\033[0;34m' 14 | YELLOW='\033[1;33m' 15 | RED='\033[0;31m' 16 | NC='\033[0m' 17 | 18 | # Backup directory 19 | BACKUP_DIR="$HOME/.dotfiles-backup/$(date +%Y%m%d-%H%M%S)" 20 | 21 | # Function to create backup 22 | backup_if_exists() { 23 | local target="$1" 24 | local backup_name="$2" 25 | 26 | if [ -e "$target" ]; then 27 | mkdir -p "$BACKUP_DIR" 28 | if [ -d "$target" ]; then 29 | cp -r "$target" "$BACKUP_DIR/$backup_name" 30 | else 31 | cp "$target" "$BACKUP_DIR/$backup_name" 32 | fi 33 | echo -e "${YELLOW} 📦 Backed up existing $backup_name${NC}" 34 | return 0 35 | fi 36 | return 1 37 | } 38 | 39 | # Function to install a config 40 | install_config() { 41 | local source="$1" 42 | local dest="$2" 43 | local name="$3" 44 | local backup_name="${4:-$(basename "$dest")}" 45 | 46 | if [ ! -e "$source" ]; then 47 | echo -e "${RED} ✗ Source not found: $source${NC}" 48 | return 1 49 | fi 50 | 51 | # Create parent directory if needed 52 | mkdir -p "$(dirname "$dest")" 53 | 54 | # Backup existing config 55 | backup_if_exists "$dest" "$backup_name" 56 | 57 | # Install new config 58 | if [ -d "$source" ]; then 59 | rsync -av --delete "$source/" "$dest/" 60 | else 61 | cp "$source" "$dest" 62 | fi 63 | 64 | echo -e "${GREEN} ✓ Installed $name${NC}" 65 | } 66 | 67 | # Check if running from repo root 68 | if [ ! -f "install.sh" ]; then 69 | echo -e "${RED}Error: Run this script from the dotfiles repo root!${NC}" 70 | exit 1 71 | fi 72 | 73 | # Zsh 74 | echo -e "${BLUE}Installing Zsh config...${NC}" 75 | install_config .zshrc ~/.zshrc "zshrc" 76 | 77 | # Install Oh My Zsh if not present 78 | if [ ! -d "$HOME/.oh-my-zsh" ]; then 79 | echo -e "${BLUE}Installing Oh My Zsh...${NC}" 80 | sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended 81 | echo -e "${GREEN} ✓ Installed Oh My Zsh${NC}" 82 | fi 83 | 84 | # Install Zsh plugins 85 | echo -e "${BLUE}Installing Zsh plugins...${NC}" 86 | ZSH_CUSTOM="${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}" 87 | 88 | if [ ! -d "$ZSH_CUSTOM/plugins/zsh-autosuggestions" ]; then 89 | git clone https://github.com/zsh-users/zsh-autosuggestions "$ZSH_CUSTOM/plugins/zsh-autosuggestions" 90 | echo -e "${GREEN} ✓ Installed zsh-autosuggestions${NC}" 91 | fi 92 | 93 | if [ ! -d "$ZSH_CUSTOM/plugins/zsh-syntax-highlighting" ]; then 94 | git clone https://github.com/zsh-users/zsh-syntax-highlighting.git "$ZSH_CUSTOM/plugins/zsh-syntax-highlighting" 95 | echo -e "${GREEN} ✓ Installed zsh-syntax-highlighting${NC}" 96 | fi 97 | 98 | # Pure prompt 99 | if [ ! -d "$ZSH_CUSTOM/plugins/pure" ]; then 100 | mkdir -p "$ZSH_CUSTOM/plugins/pure" 101 | git clone https://github.com/sindresorhus/pure.git "$ZSH_CUSTOM/plugins/pure" 102 | ln -sf "$ZSH_CUSTOM/plugins/pure/pure.zsh" "$HOME/.zsh/pure/prompt_pure_setup" 103 | ln -sf "$ZSH_CUSTOM/plugins/pure/async.zsh" "$HOME/.zsh/pure/async" 104 | echo -e "${GREEN} ✓ Installed pure prompt${NC}" 105 | fi 106 | 107 | # Zellij 108 | echo -e "${BLUE}Installing Zellij config...${NC}" 109 | install_config zellij/config.kdl ~/.config/zellij/config.kdl "config" 110 | install_config zellij/themes ~/.config/zellij/themes "themes" "zellij-themes" 111 | install_config zellij/layouts ~/.config/zellij/layouts "layouts" "zellij-layouts" 112 | install_config zellij/zellij-sessionizer.sh ~/.config/zellij/zellij-sessionizer.sh "sessionizer" 113 | chmod +x ~/.config/zellij/zellij-sessionizer.sh 114 | install_config zellij/README.md ~/.config/zellij/README.md "README" 115 | 116 | # Atuin 117 | echo -e "${BLUE}Installing Atuin config...${NC}" 118 | install_config atuin/config.toml ~/.config/atuin/config.toml "config" 119 | install_config atuin/themes ~/.config/atuin/themes "themes" "atuin-themes" 120 | install_config atuin/README.md ~/.config/atuin/README.md "README" 121 | 122 | # Ghostty 123 | echo -e "${BLUE}Installing Ghostty config...${NC}" 124 | GHOSTTY_DIR="$HOME/Library/Application Support/com.mitchellh.ghostty" 125 | install_config ghostty/config "$GHOSTTY_DIR/config" "config" 126 | install_config ghostty/switch-theme.sh "$GHOSTTY_DIR/switch-theme.sh" "theme switcher" 127 | chmod +x "$GHOSTTY_DIR/switch-theme.sh" 128 | install_config ghostty/README.md "$GHOSTTY_DIR/README.md" "README" 129 | 130 | # Karabiner 131 | echo -e "${BLUE}Installing Karabiner config...${NC}" 132 | install_config karabiner/karabiner.edn ~/.config/karabiner.edn "config" 133 | install_config karabiner/README.md ~/.config/karabiner/README.md "README" 134 | 135 | # Check for required tools 136 | echo "" 137 | echo -e "${BLUE}Checking required tools...${NC}" 138 | 139 | check_tool() { 140 | local tool="$1" 141 | local install_cmd="$2" 142 | 143 | if command -v "$tool" &> /dev/null; then 144 | echo -e "${GREEN} ✓ $tool is installed${NC}" 145 | else 146 | echo -e "${YELLOW} ⚠ $tool is not installed${NC}" 147 | echo -e " Install with: $install_cmd" 148 | fi 149 | } 150 | 151 | check_tool "zellij" "brew install zellij" 152 | check_tool "atuin" "brew install atuin" 153 | check_tool "ghostty" "Download from https://ghostty.org" 154 | check_tool "goku" "brew install yqrashawn/goku/goku" 155 | check_tool "fd" "brew install fd" 156 | check_tool "fzf" "brew install fzf" 157 | check_tool "tree" "brew install tree" 158 | check_tool "nvim" "brew install neovim" 159 | check_tool "rsync" "brew install rsync" 160 | 161 | echo "" 162 | if [ -d "$BACKUP_DIR" ]; then 163 | echo -e "${YELLOW}📦 Backups saved to: $BACKUP_DIR${NC}" 164 | fi 165 | echo -e "${GREEN}✨ Installation complete!${NC}" 166 | echo "" 167 | echo "Restart your terminal or run: source ~/.zshrc" 168 | echo "" 169 | echo "To sync changes back to the repo, run: ./sync-from-system.sh" -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Joel's Dotfiles 🚀 2 | 3 | > A highly optimized macOS development environment featuring Zsh, Zellij, Ghostty, Atuin, and Karabiner configurations. 4 | 5 | ![Catppuccin Macchiato](https://img.shields.io/badge/theme-catppuccin%20macchiato-purple?style=for-the-badge) 6 | ![Zsh](https://img.shields.io/badge/shell-zsh-green?style=for-the-badge) 7 | ![macOS](https://img.shields.io/badge/os-macOS-blue?style=for-the-badge) 8 | 9 | ## 🎨 Preview 10 | 11 | This setup features: 12 | - **Catppuccin Macchiato** theme across all tools 13 | - **1 million line** scrollback in terminals 14 | - **GPU-accelerated** terminal rendering 15 | - **Fuzzy history search** with context awareness 16 | - **Advanced keyboard customization** with Karabiner 17 | - **Session persistence** with Zellij 18 | 19 | ## 📦 What's Included 20 | 21 | ### [Zsh](.zshrc) - Shell Configuration 22 | - Oh My Zsh with performance optimizations 23 | - Smart aliases and functions 24 | - FZF integration 25 | - Homebrew & pnpm paths 26 | - Pure prompt 27 | 28 | ### [Zellij](zellij/) - Terminal Multiplexer 29 | - Session management with persistence 30 | - Custom layouts for development 31 | - Project sessionizer script 32 | - Catppuccin themes 33 | - 1M line scrollback 34 | 35 | ### [Ghostty](ghostty/) - GPU Terminal Emulator 36 | - Native macOS integration 37 | - GPU-accelerated rendering 38 | - 1M line scrollback 39 | - Catppuccin theme switcher 40 | - Optimized keybindings 41 | 42 | ### [Atuin](atuin/) - Shell History 43 | - Fuzzy search with 25-line preview 44 | - Context-aware filtering (directory/workspace) 45 | - Privacy-focused configuration 46 | - Catppuccin themes (4 accent colors) 47 | - Smart command filtering 48 | 49 | ### [Karabiner](karabiner/) - Keyboard Customization 50 | - Caps Lock → Escape/Control 51 | - Home row modifiers 52 | - Vim-style navigation 53 | - App-specific shortcuts 54 | - Emoji layer 55 | 56 | ## 🛠 Installation 57 | 58 | ### Quick Install 59 | 60 | ```bash 61 | git clone https://github.com/joelhooks/dotfiles.git ~/Code/joelhooks/dotfiles 62 | cd ~/Code/joelhooks/dotfiles 63 | ./install.sh 64 | ``` 65 | 66 | ### Manual Installation 67 | 68 | Each tool can be installed individually by copying its config files to the appropriate location. See the [install script](install.sh) for details. 69 | 70 | ## 📚 Documentation 71 | 72 | Each tool includes comprehensive documentation: 73 | 74 | - [Zsh Configuration](.zshrc) - Aliases and functions 75 | - [Zellij Documentation](zellij/) - Keybindings and layouts 76 | - [Ghostty Documentation](ghostty/) - Terminal shortcuts 77 | - [Atuin Documentation](atuin/) - Search operators 78 | - [Karabiner Documentation](karabiner/) - Keyboard layers 79 | 80 | ## ⚡ Key Features 81 | 82 | ### Productivity Shortcuts 83 | 84 | | Shortcut | Action | 85 | |----------|--------| 86 | | `Ctrl+f` | Zellij project sessionizer | 87 | | `Ctrl+r` | Atuin fuzzy history search | 88 | | `Alt+1-9` | Quick tab switching | 89 | | `Caps Lock` | Escape (tap) / Control (hold) | 90 | 91 | ### Quick Commands 92 | 93 | | Command | Description | 94 | |---------|-------------| 95 | | `zj` | Start Zellij | 96 | | `zs` | Project sessionizer | 97 | | `h` | Atuin search | 98 | | `hs` | History stats | 99 | | `ht` | Switch Atuin theme | 100 | | `gt` | Switch Ghostty theme | 101 | | `v` | Neovim | 102 | | `c` | Cursor editor | 103 | 104 | ### Development Aliases 105 | 106 | | Alias | Command | 107 | |-------|---------| 108 | | `p` | pnpm | 109 | | `px` | pnpm dlx | 110 | | `gst` | git status (short) | 111 | | `glog` | git log (graph) | 112 | | `dev` | cd ~/Code | 113 | | `mkd` | Create & enter directory | 114 | 115 | ## 🎨 Theme Consistency 116 | 117 | All tools are configured with **Catppuccin Macchiato** for a consistent look: 118 | 119 | - Terminal colors 120 | - UI elements 121 | - Syntax highlighting 122 | - Status bars 123 | 124 | Theme switchers are included for easy customization: 125 | - `ht` - Switch Atuin theme 126 | - `gt` - Switch Ghostty theme 127 | 128 | ## 🔧 Requirements 129 | 130 | ### Required Tools 131 | - [Homebrew](https://brew.sh) 132 | - [Oh My Zsh](https://ohmyz.sh) 133 | - [Zellij](https://zellij.dev) 134 | - [Ghostty](https://ghostty.org) 135 | - [Atuin](https://atuin.sh) 136 | - [Karabiner-Elements](https://karabiner-elements.pqrs.org) 137 | - [Goku](https://github.com/yqrashawn/GokuRakuJoudo) (for Karabiner EDN) 138 | 139 | ### Fonts 140 | - [Dank Mono](https://dank.sh) (primary) 141 | - [JetBrains Mono](https://www.jetbrains.com/lp/mono/) (fallback) 142 | 143 | ## 📁 Structure 144 | 145 | ``` 146 | . 147 | ├── .zshrc # Zsh configuration 148 | ├── zellij/ # Zellij configs 149 | │ ├── config.kdl # Main config 150 | │ ├── layouts/ # Custom layouts 151 | │ ├── themes/ # Catppuccin themes 152 | │ └── zellij-sessionizer.sh # Project switcher 153 | ├── ghostty/ # Ghostty terminal 154 | │ ├── config # Main config 155 | │ └── switch-theme.sh # Theme switcher 156 | ├── atuin/ # Shell history 157 | │ ├── config.toml # Main config 158 | │ └── themes/ # Catppuccin themes 159 | ├── karabiner/ # Keyboard config 160 | │ └── karabiner.edn # Goku config 161 | └── install.sh # Installation script 162 | ``` 163 | 164 | ## 🚀 Post-Installation 165 | 166 | 1. **Restart your terminal** or run `source ~/.zshrc` 167 | 2. **Install Zsh plugins**: 168 | ```bash 169 | git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions 170 | git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting 171 | ``` 172 | 3. **Compile Karabiner config**: `goku` 173 | 4. **Start using the tools**: 174 | - Launch Zellij: `zj` 175 | - Search history: `Ctrl+r` 176 | - Switch projects: `Ctrl+f` 177 | 178 | ## 🤝 Contributing 179 | 180 | Feel free to fork and customize! If you have improvements, PRs are welcome. 181 | 182 | ## 📄 License 183 | 184 | MIT - Use freely and customize to your heart's content. 185 | 186 | --- 187 | 188 | *Built with ❤️ and excessive attention to detail* -------------------------------------------------------------------------------- /atuin/README.md: -------------------------------------------------------------------------------- 1 | # Atuin Cheatsheet 🔥 2 | 3 | ## What is Atuin? 4 | Magical shell history that syncs across machines, with smart search and statistics. 5 | 6 | ## Core Features 7 | - **Fuzzy Search**: Find commands instantly 8 | - **Context Awareness**: Filter by directory, host, session 9 | - **Statistics**: Track command usage 10 | - **Sync**: Optional cross-machine history 11 | - **Privacy**: Client-side encryption 12 | 13 | ## Keybindings 14 | 15 | ### Search Mode (`Ctrl+r` or `↑`) 16 | | Key | Action | 17 | |-----|--------| 18 | | `Ctrl+r` | Open fuzzy search | 19 | | `↑` | Context-aware history (directory) | 20 | | `Enter` | Execute selected command | 21 | | `Tab` | Copy to shell for editing | 22 | | `Ctrl+o` | Open inspector | 23 | | `Ctrl+d` | Delete entry | 24 | | `Esc` | Exit search | 25 | 26 | ### Navigation 27 | - `↑/↓` or `j/k` - Navigate results (won't exit at boundaries) 28 | - `PageUp/PageDown` - Page through results 29 | - `Ctrl+u/d` - Half page up/down 30 | - `Home/End` - Jump to start/end 31 | - `←` - Move cursor (won't exit search) 32 | - `→` - Accept line (same as Tab) 33 | - `Ctrl+1-9` - Quick shortcuts (macOS friendly) 34 | 35 | ### Filters (during search) 36 | - `Ctrl+h` - Filter: host 37 | - `Ctrl+s` - Filter: session 38 | - `Ctrl+d` - Filter: directory 39 | - `Ctrl+w` - Filter: workspace 40 | - `Ctrl+g` - Filter: global (all) 41 | - `Ctrl+i` - Invert search 42 | 43 | ## Command Line 44 | 45 | ### Search & History 46 | ```bash 47 | atuin search # Interactive search 48 | atuin search --cmd "git" # Search for commands 49 | atuin search --before 2d # Commands from 2 days ago 50 | atuin search --limit 50 # Limit results 51 | h # Alias for search (custom) 52 | 53 | atuin history list # List all history 54 | atuin history last # Last command 55 | atuin history delete # Delete entry 56 | hd # Alias for delete (custom) 57 | ``` 58 | 59 | ### Statistics 60 | ```bash 61 | atuin stats # Overall statistics 62 | atuin stats day # Today's stats 63 | atuin stats week # This week's stats 64 | hs # Alias for stats (custom) 65 | 66 | # Examples 67 | atuin stats | head -20 # Top 20 commands 68 | atuin stats day --cmd git # Git commands today 69 | ``` 70 | 71 | ### Sync (Optional) 72 | ```bash 73 | atuin register # Create account 74 | atuin login # Login to sync 75 | atuin logout # Stop syncing 76 | atuin sync # Manual sync 77 | atuin key # Show encryption key 78 | ``` 79 | 80 | ### Import History 81 | ```bash 82 | atuin import bash # Import from bash 83 | atuin import zsh # Import from zsh 84 | atuin import fish # Import from fish 85 | atuin import auto # Auto-detect shell 86 | ``` 87 | 88 | ## Configuration 89 | 90 | ### Key Settings (in config.toml) 91 | ```toml 92 | # Search 93 | search_mode = "fuzzy" # fuzzy, prefix, fulltext 94 | filter_mode = "global" # Default filter mode 95 | filter_mode_shell_up_key_binding = "directory" # Up arrow uses directory context 96 | workspaces = true # Git workspace awareness enabled 97 | inline_height = 0 # Maximum visibility (full screen) 98 | 99 | # UI 100 | style = "auto" # Adaptive layout 101 | show_preview = true # Show command preview 102 | max_preview_height = 20 # See lots more context 103 | invert = false # Search bar at bottom 104 | show_help = false # Cleaner UI 105 | show_tabs = true # Show search/inspect tabs 106 | 107 | # Navigation 108 | ctrl_n_shortcuts = true # Use Ctrl+1-9 (better for macOS) 109 | scroll_exits = false # Keep browsing at boundaries 110 | exit_past_line_start = false # Don't exit on left arrow 111 | 112 | # History 113 | history_filter = [ # Comprehensive filters 114 | # Security 115 | "^secret", "password=", "token=", "api_key=", 116 | # Noise 117 | "^ls$", "^cd$", "^pwd$", "^exit$", 118 | # Typos 119 | "^[^a-zA-Z]", "^\\s" 120 | ] 121 | secrets_filter = true # Auto-filter secrets 122 | enter_accept = true # Enter runs command 123 | 124 | # Performance 125 | sync_frequency = "30m" # Sync interval 126 | auto_sync = true # Enable auto sync 127 | update_check = false # Manual update checks 128 | local_timeout = 2 # Fast local DB 129 | ``` 130 | 131 | ### Custom Aliases (from .zshrc) 132 | ```bash 133 | h # Quick history search 134 | hs # History statistics 135 | hd # Delete history entry 136 | ht # Theme switcher 137 | ``` 138 | 139 | ## Filter Modes 140 | 141 | Default filter priority order: 142 | 1. **Workspace** - Current git repository (when in a repo) 143 | 2. **Directory** - Current directory only (default for ↑ arrow) 144 | 3. **Global** - All commands from all time 145 | 4. **Host** - Only from current machine 146 | 5. **Session** - Current shell session only 147 | 148 | **Switch modes**: Use Ctrl+w/d/g/h/s during search 149 | 150 | **Note**: Up arrow uses directory filter by default for context-aware history! 151 | 152 | ## Search Syntax 153 | 154 | ### Fuzzy Search (default) 155 | - `gco` finds `git checkout` 156 | - `dcup` finds `docker-compose up` 157 | 158 | ### Operators 159 | - `^term` - Starts with 160 | - `term$` - Ends with 161 | - `!term` - Exclude term 162 | - `term1 term2` - Both terms 163 | 164 | ### Time Filters 165 | - `--before 1d` - Before 1 day ago 166 | - `--after 2w` - After 2 weeks ago 167 | - `--limit 100` - Limit results 168 | 169 | ## Current Theme 170 | 171 | **Catppuccin Macchiato Mauve** 🎨 172 | 173 | ### Switch Themes 174 | Run `ht` to switch between: 175 | 1. Mauve (purple) - Current 176 | 2. Blue 177 | 3. Green 178 | 4. Pink 179 | 180 | ## Tips & Tricks 181 | 182 | 1. **Quick Re-run**: Press `↑` for directory-specific history 183 | 2. **Edit Before Run**: Press `Tab` instead of `Enter` 184 | 3. **Clean History**: Use regex filters to exclude noise 185 | 4. **Project Context**: Workspace mode for git repos 186 | 5. **Privacy**: Passwords auto-filtered, add custom filters 187 | 6. **Speed**: Indexes 1M+ commands instantly 188 | 189 | ## Stats Insights 190 | 191 | ```bash 192 | # Most used commands 193 | atuin stats | head -10 194 | 195 | # Commands by day of week 196 | atuin stats day 197 | 198 | # Specific command usage 199 | atuin stats --cmd docker 200 | 201 | # Time-based analysis 202 | atuin stats --before 1w --after 2w 203 | ``` 204 | 205 | **Enhanced subcommand tracking** for: 206 | - git, docker, npm, pnpm, yarn 207 | - kubectl, terraform, aws, gcloud, az 208 | - brew, cargo, go, gh, vercel 209 | - systemctl, tmux, apt, dnf, nix 210 | 211 | ## Troubleshooting 212 | 213 | ```bash 214 | # Check database 215 | atuin doctor 216 | 217 | # Database location 218 | ~/.local/share/atuin/history.db 219 | 220 | # Config location 221 | ~/.config/atuin/config.toml 222 | 223 | # Clear search cache 224 | rm -rf ~/.local/share/atuin/cache 225 | ``` 226 | 227 | ## Privacy Features 228 | 229 | - Local-first (sync optional) 230 | - Client-side encryption 231 | - Automatic secret filtering 232 | - Custom filter patterns 233 | - Directory-based filtering 234 | 235 | ## Advanced Usage 236 | 237 | ### Custom Filters 238 | ```toml 239 | history_filter = [ 240 | "^secret", 241 | "password=", 242 | "token=.*", 243 | ] 244 | 245 | cwd_filter = [ 246 | "/private/", 247 | "/tmp/", 248 | ] 249 | ``` 250 | 251 | ### Integration 252 | - Works with any shell 253 | - Preserves existing history 254 | - Non-invasive (can disable anytime) 255 | - Supports command duration tracking -------------------------------------------------------------------------------- /.zshrc: -------------------------------------------------------------------------------- 1 | # If you come from bash you might have to change your $PATH. 2 | # export PATH=$HOME/bin:$HOME/.local/bin:/usr/local/bin:$PATH 3 | 4 | # Path to your Oh My Zsh installation. 5 | export ZSH="$HOME/.oh-my-zsh" 6 | 7 | # Set name of the theme to load --- if set to "random", it will 8 | # load a random theme each time Oh My Zsh is loaded, in which case, 9 | # to know which specific one was loaded, run: echo $RANDOM_THEME 10 | # See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes 11 | ZSH_THEME="" # Disabled since we're using pure prompt 12 | 13 | # Performance optimizations 14 | zstyle ':omz:lib:directories' aliases no # Disable directory aliases for speed 15 | zstyle ':completion:*' use-cache on 16 | zstyle ':completion:*' cache-path "$HOME/.zsh/cache" 17 | DISABLE_UNTRACKED_FILES_DIRTY="true" # Faster git status in large repos 18 | DISABLE_AUTO_UPDATE="true" # Disable auto-update checks 19 | 20 | # Which plugins would you like to load? 21 | # Standard plugins can be found in $ZSH/plugins/ 22 | # Custom plugins may be added to $ZSH_CUSTOM/plugins/ 23 | # Example format: plugins=(rails git textmate ruby lighthouse) 24 | # Add wisely, as too many plugins slow down shell startup. 25 | plugins=( 26 | git 27 | z # Jump around directories 28 | macos # macOS specific utils 29 | brew # Homebrew completions 30 | docker # Docker completions 31 | docker-compose 32 | npm # npm completions 33 | zsh-autosuggestions # Fish-like autosuggestions 34 | zsh-syntax-highlighting # Fish-like syntax highlighting 35 | fzf # Fuzzy finder 36 | ) 37 | 38 | # Load custom plugins (install these first) 39 | # git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions 40 | # git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting 41 | 42 | source $ZSH/oh-my-zsh.sh 43 | 44 | # User configuration 45 | 46 | # Homebrew paths (Apple Silicon compatible) 47 | if [[ -d "/opt/homebrew" ]]; then 48 | export PATH="/opt/homebrew/bin:/opt/homebrew/sbin:$PATH" 49 | export HOMEBREW_PREFIX="/opt/homebrew" 50 | else 51 | export PATH="/usr/local/bin:/usr/local/sbin:$PATH" 52 | export HOMEBREW_PREFIX="/usr/local" 53 | fi 54 | 55 | # pnpm global binaries 56 | export PNPM_HOME="$HOME/Library/pnpm" 57 | export PATH="$PNPM_HOME:$PATH" 58 | 59 | # Language settings 60 | export LANG=en_US.UTF-8 61 | export LC_ALL=en_US.UTF-8 62 | 63 | # History optimization 64 | export HISTSIZE=100000 65 | export SAVEHIST=100000 66 | export HISTFILE="$HOME/.zsh_history" 67 | setopt EXTENDED_HISTORY # Write the history file in the ':start:elapsed;command' format 68 | setopt INC_APPEND_HISTORY # Write to the history file immediately, not when the shell exits 69 | setopt SHARE_HISTORY # Share history between all sessions 70 | setopt HIST_EXPIRE_DUPS_FIRST # Expire a duplicate event first when trimming history 71 | setopt HIST_IGNORE_DUPS # Do not record an event that was just recorded again 72 | setopt HIST_IGNORE_ALL_DUPS # Delete an old recorded event if a new event is a duplicate 73 | setopt HIST_FIND_NO_DUPS # Do not display a previously found event 74 | setopt HIST_IGNORE_SPACE # Do not record an event starting with a space 75 | setopt HIST_SAVE_NO_DUPS # Do not write a duplicate event to the history file 76 | setopt HIST_VERIFY # Do not execute immediately upon history expansion 77 | 78 | # Performance: Disable less common features 79 | setopt NO_BEEP 80 | setopt NO_FLOW_CONTROL 81 | setopt NO_MAIL_WARNING 82 | unsetopt BG_NICE 83 | 84 | # Enable better globbing 85 | setopt EXTENDED_GLOB 86 | setopt NULL_GLOB 87 | 88 | # macOS specific settings 89 | export CLICOLOR=1 90 | export LSCOLORS=ExGxBxDxCxEgEdxbxgxcxd 91 | 92 | # Better ls aliases 93 | alias ls='ls -GF' 94 | alias ll='ls -lhAGF' 95 | alias la='ls -AGF' 96 | alias l='ls -CF' 97 | 98 | # macOS specific aliases 99 | alias showfiles='defaults write com.apple.finder AppleShowAllFiles YES; killall Finder' 100 | alias hidefiles='defaults write com.apple.finder AppleShowAllFiles NO; killall Finder' 101 | alias flushdns='sudo dscacheutil -flushcache && sudo killall -HUP mDNSResponder' 102 | alias afk='/System/Library/CoreServices/Menu\ Extras/User.menu/Contents/Resources/CGSession -suspend' 103 | alias cleanup="find . -type f -name '*.DS_Store' -ls -delete" 104 | alias emptytrash="sudo rm -rfv /Volumes/*/.Trashes; sudo rm -rfv ~/.Trash; sudo rm -rfv /private/var/log/asl/*.asl" 105 | 106 | # Git aliases (beyond what git plugin provides) 107 | alias gst='git status -sb' 108 | alias glog='git log --oneline --graph --decorate' 109 | alias gdiff='git diff --color-words' 110 | alias gclean='git clean -fd && git checkout -- .' 111 | alias gnuke='git reset --hard && git clean -fd' 112 | 113 | # Development aliases 114 | alias dev='cd ~/Code' 115 | alias vim="nvim" 116 | alias v="nvim" 117 | alias c="cursor" 118 | alias p="pnpm" 119 | alias px="pnpm dlx" 120 | alias pdev="pnpm dev" 121 | alias pbuild="pnpm build" 122 | alias ptest="pnpm test" 123 | 124 | # Docker aliases 125 | alias dps='docker ps --format "table {{.Names}}\t{{.Status}}\t{{.Ports}}"' 126 | alias dclean='docker system prune -af' 127 | alias dstop='docker stop $(docker ps -aq)' 128 | alias drm='docker rm $(docker ps -aq)' 129 | 130 | # Quick navigation 131 | alias ..='cd ..' 132 | alias ...='cd ../..' 133 | alias ....='cd ../../..' 134 | alias .....='cd ../../../..' 135 | alias ~='cd ~' 136 | alias -- -='cd -' 137 | 138 | # Zellij aliases 139 | alias zj='zellij' 140 | alias zja='zellij attach' 141 | alias zjl='zellij list-sessions' 142 | alias zjk='zellij kill-session' 143 | alias zjka='zellij kill-all-sessions' 144 | alias zjd='zellij --layout dev' 145 | alias zs='~/.config/zellij/zellij-sessionizer.sh' 146 | bindkey -s '^f' 'zs\n' # Ctrl+f to launch sessionizer 147 | 148 | # Useful functions 149 | mkd() { mkdir -p "$@" && cd "$_"; } 150 | tre() { tree -aC -I '.git|node_modules|.next|dist|build' --dirsfirst "$@" | less -FRNX; } 151 | extract() { 152 | if [ -f $1 ]; then 153 | case $1 in 154 | *.tar.bz2) tar xjf $1 ;; 155 | *.tar.gz) tar xzf $1 ;; 156 | *.bz2) bunzip2 $1 ;; 157 | *.rar) unrar e $1 ;; 158 | *.gz) gunzip $1 ;; 159 | *.tar) tar xf $1 ;; 160 | *.tbz2) tar xjf $1 ;; 161 | *.tgz) tar xzf $1 ;; 162 | *.zip) unzip $1 ;; 163 | *.Z) uncompress $1 ;; 164 | *.7z) 7z x $1 ;; 165 | *) echo "'$1' cannot be extracted via extract()" ;; 166 | esac 167 | else 168 | echo "'$1' is not a valid file" 169 | fi 170 | } 171 | ht() { 172 | echo "🎨 Catppuccin Macchiato themes:" 173 | echo "1. Mauve (purple)" 174 | echo "2. Blue" 175 | echo "3. Green" 176 | echo "4. Pink" 177 | echo -n "Select (1-4): " 178 | read choice 179 | case $choice in 180 | 1) theme="catppuccin-macchiato-mauve" ;; 181 | 2) theme="catppuccin-macchiato-blue" ;; 182 | 3) theme="catppuccin-macchiato-green" ;; 183 | 4) theme="catppuccin-macchiato-pink" ;; 184 | *) echo "❌ Invalid choice"; return 1 ;; 185 | esac 186 | sed -i '' "s/name = \".*\"/name = \"$theme\"/" ~/.config/atuin/config.toml 187 | echo "✅ Theme switched to $theme!" 188 | echo "🚀 Press Ctrl+R to see the new theme" 189 | } 190 | 191 | # Pure prompt 192 | autoload -U promptinit; promptinit 193 | prompt pure 194 | 195 | # fnm 196 | FNM_PATH="$HOME/.local/share/fnm" 197 | if [ -d "$FNM_PATH" ]; then 198 | export PATH="$FNM_PATH:$PATH" 199 | eval "$(fnm env --use-on-cd --shell zsh)" 200 | fi 201 | 202 | # atuin - enhanced shell history 203 | . "$HOME/.atuin/bin/env" 204 | eval "$(atuin init zsh)" 205 | 206 | # Atuin key bindings 207 | bindkey '^r' atuin-search # Ctrl+R for fuzzy history search 208 | bindkey '^[[A' atuin-up # Up arrow for context-aware history 209 | bindkey '^[OA' atuin-up # Up arrow (alternate) 210 | 211 | # Atuin aliases 212 | alias h='atuin search' # Quick history search 213 | alias hs='atuin stats' # History statistics 214 | alias hd='atuin history delete' # Delete history entry 215 | # alias ht defined below as function 216 | alias gt='~/Library/Application\ Support/com.mitchellh.ghostty/switch-theme.sh' # Switch Ghostty theme 217 | 218 | # Editors 219 | export EDITOR="nvim" 220 | export GIT_EDITOR="nvim" 221 | export VISUAL="cursor" 222 | 223 | # FZF configuration 224 | export FZF_DEFAULT_COMMAND='fd --type f --hidden --follow --exclude .git' 225 | export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND" 226 | export FZF_DEFAULT_OPTS='--height 40% --layout=reverse --border --color=dark' 227 | 228 | # FZF shell integration 229 | [ -f ~/.fzf.zsh ] && source ~/.fzf.zsh 230 | 231 | # Load local config if exists 232 | [[ -f ~/.zshrc.local ]] && source ~/.zshrc.local -------------------------------------------------------------------------------- /atuin/config.toml: -------------------------------------------------------------------------------- 1 | ## where to store your database, default is your system data directory 2 | ## linux/mac: ~/.local/share/atuin/history.db 3 | ## windows: %USERPROFILE%/.local/share/atuin/history.db 4 | # db_path = "~/.history.db" 5 | 6 | ## where to store your encryption key, default is your system data directory 7 | ## linux/mac: ~/.local/share/atuin/key 8 | ## windows: %USERPROFILE%/.local/share/atuin/key 9 | # key_path = "~/.key" 10 | 11 | ## where to store your auth session token, default is your system data directory 12 | ## linux/mac: ~/.local/share/atuin/session 13 | ## windows: %USERPROFILE%/.local/share/atuin/session 14 | # session_path = "~/.session" 15 | 16 | ## date format used, either "us" or "uk" 17 | dialect = "us" 18 | 19 | ## default timezone to use when displaying time 20 | ## either "l", "local" to use the system's current local timezone, or an offset 21 | ## from UTC in the format of "<+|->H[H][:M[M][:S[S]]]" 22 | ## for example: "+9", "-05", "+03:30", "-01:23:45", etc. 23 | timezone = "local" 24 | 25 | ## enable or disable automatic sync 26 | auto_sync = true 27 | 28 | ## enable or disable automatic update checks 29 | update_check = false # We check manually 30 | 31 | ## address of the sync server 32 | # sync_address = "https://api.atuin.sh" 33 | 34 | ## how often to sync history. note that this is only triggered when a command 35 | ## is ran, so sync intervals may well be longer 36 | ## set it to 0 to sync after every command 37 | sync_frequency = "30m" 38 | 39 | ## which search mode to use 40 | ## possible values: prefix, fulltext, fuzzy, skim 41 | search_mode = "fuzzy" # Best for finding commands 42 | 43 | ## which filter mode to use by default 44 | ## possible values: "global", "host", "session", "directory", "workspace" 45 | ## consider using search.filters to customize the enablement and order of filter modes 46 | filter_mode = "global" 47 | 48 | ## With workspace filtering enabled, Atuin will filter for commands executed 49 | ## in any directory within a git repository tree (default: false). 50 | ## 51 | ## To use workspace mode by default when available, set this to true and 52 | ## set filter_mode to "workspace" or leave it unspecified and 53 | ## set search.filters to include "workspace" before other filter modes. 54 | workspaces = true # Enable git workspace awareness 55 | 56 | ## which filter mode to use when atuin is invoked from a shell up-key binding 57 | ## the accepted values are identical to those of "filter_mode" 58 | ## leave unspecified to use same mode set in "filter_mode" 59 | filter_mode_shell_up_key_binding = "directory" # Context-aware on up arrow 60 | 61 | ## which search mode to use when atuin is invoked from a shell up-key binding 62 | ## the accepted values are identical to those of "search_mode" 63 | ## leave unspecified to use same mode set in "search_mode" 64 | # search_mode_shell_up_key_binding = "fuzzy" 65 | 66 | ## which style to use 67 | ## possible values: auto, full, compact 68 | style = "auto" # More space efficient 69 | 70 | ## the maximum number of lines the interface should take up 71 | ## set it to 0 to always go full screen 72 | inline_height = 0 # Maximum visibility 73 | 74 | ## Invert the UI - put the search bar at the top , Default to `false` 75 | invert = false 76 | 77 | ## enable or disable showing a preview of the selected command 78 | ## useful when the command is longer than the terminal width and is cut off 79 | show_preview = true 80 | 81 | ## what to do when the escape key is pressed when searching 82 | ## possible values: return-original, return-query 83 | exit_mode = "return-original" 84 | 85 | ## possible values: emacs, subl 86 | word_jump_mode = "emacs" 87 | 88 | ## characters that count as a part of a word 89 | word_chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_-." 90 | 91 | ## number of context lines to show when scrolling by pages 92 | scroll_context_lines = 3 93 | 94 | ## use ctrl instead of alt as the shortcut modifier key for numerical UI shortcuts 95 | ## alt-0 .. alt-9 96 | ctrl_n_shortcuts = true # Better for macOS 97 | 98 | ## default history list format - can also be specified with the --format arg 99 | history_format = "{time} │ {duration} │ {command}" 100 | 101 | ## prevent commands matching any of these regexes from being written to history. 102 | ## Note that these regular expressions are unanchored, i.e. if they don't start 103 | ## with ^ or end with $, they'll match anywhere in the command. 104 | ## For details on the supported regular expression syntax, see 105 | ## https://docs.rs/regex/latest/regex/#syntax 106 | history_filter = [ 107 | # Security sensitive 108 | "^secret", 109 | "password=", 110 | "passwd", 111 | "token=", 112 | "api_key=", 113 | "apikey=", 114 | "--password", 115 | "AWS_SECRET", 116 | "GITHUB_TOKEN", 117 | 118 | # Noise commands 119 | "^ls$", 120 | "^cd$", 121 | "^pwd$", 122 | "^exit$", 123 | "^clear$", 124 | "^history$", 125 | 126 | # Typos and accidents 127 | "^[^a-zA-Z]", # Commands starting with non-letters 128 | "^\\s", # Commands starting with space 129 | ] 130 | 131 | ## prevent commands run with cwd matching any of these regexes from being written 132 | ## to history. Note that these regular expressions are unanchored, i.e. if they don't 133 | ## start with ^ or end with $, they'll match anywhere in CWD. 134 | ## For details on the supported regular expression syntax, see 135 | ## https://docs.rs/regex/latest/regex/#syntax 136 | cwd_filter = [ 137 | "/tmp/", 138 | "/.git/", 139 | "/private/", 140 | ] 141 | 142 | ## Configure the maximum height of the preview to show. 143 | ## Useful when you have long scripts in your history that you want to distinguish 144 | ## by more than the first few lines. 145 | max_preview_height = 20 # See LOTS more context 146 | 147 | ## Configure whether or not to show the help row, which includes the current Atuin 148 | ## version (and whether an update is available), a keymap hint, and the total 149 | ## amount of commands in your history. 150 | show_help = false # Cleaner UI 151 | 152 | ## Configure whether or not to show tabs for search and inspect 153 | show_tabs = true 154 | 155 | ## Configure whether or not the tabs row may be auto-hidden, which includes the current Atuin 156 | ## tab, such as Search or Inspector, and other tabs you may wish to see. This will 157 | ## only be hidden if there are fewer than this count of lines available, and does not affect the use 158 | ## of keyboard shortcuts to switch tab. 0 to never auto-hide, default is 8 (lines). 159 | ## This is ignored except in `compact` mode. 160 | auto_hide_height = 6 161 | 162 | ## Defaults to true. This matches history against a set of default regex, and will not save it if we get a match. Defaults include 163 | ## 1. AWS key id 164 | ## 2. Github pat (old and new) 165 | ## 3. Slack oauth tokens (bot, user) 166 | ## 4. Slack webhooks 167 | ## 5. Stripe live/test keys 168 | secrets_filter = true 169 | 170 | ## Defaults to true. If enabled, upon hitting enter Atuin will immediately execute the command. Press tab to return to the shell and edit. 171 | # This applies for new installs. Old installs will keep the old behaviour unless configured otherwise. 172 | enter_accept = true 173 | 174 | ## Defaults to "emacs". This specifies the keymap on the startup of `atuin 175 | ## search`. If this is set to "auto", the startup keymap mode in the Atuin 176 | ## search is automatically selected based on the shell's keymap where the 177 | ## keybinding is defined. If this is set to "emacs", "vim-insert", or 178 | ## "vim-normal", the startup keymap mode in the Atuin search is forced to be 179 | ## the specified one. 180 | keymap_mode = "auto" 181 | 182 | ## Cursor style in each keymap mode. If specified, the cursor style is changed 183 | ## in entering the cursor shape. Available values are "default" and 184 | ## "{blink,steady}-{block,underline,bar}". 185 | keymap_cursor = { emacs = "blink-bar", vim_insert = "blink-bar", vim_normal = "steady-block" } 186 | 187 | network_connect_timeout = 3 188 | network_timeout = 5 189 | 190 | ## Timeout (in seconds) for acquiring a local database connection (sqlite) 191 | local_timeout = 2 192 | 193 | ## Set this to true and Atuin will minimize motion in the UI - timers will not update live, etc. 194 | ## Alternatively, set env NO_MOTION=true 195 | prefers_reduced_motion = false 196 | 197 | [stats] 198 | ## Set commands where we should consider the subcommand for statistics. Eg, kubectl get vs just kubectl 199 | common_subcommands = [ 200 | "apt", 201 | "brew", 202 | "cargo", 203 | "composer", 204 | "dnf", 205 | "docker", 206 | "git", 207 | "go", 208 | "ip", 209 | "jj", 210 | "kubectl", 211 | "nix", 212 | "nmcli", 213 | "npm", 214 | "pecl", 215 | "pnpm", 216 | "podman", 217 | "port", 218 | "systemctl", 219 | "tmux", 220 | "yarn", 221 | "gh", 222 | "aws", 223 | "az", 224 | "gcloud", 225 | "terraform", 226 | "vercel", 227 | ] 228 | 229 | ## Set commands that should be totally stripped and ignored from stats 230 | common_prefix = ["sudo", "time", "nice"] 231 | 232 | ## Set commands that will be completely ignored from stats 233 | ignored_commands = [ 234 | "cd", 235 | "ls", 236 | "vi", 237 | "ll", 238 | "la", 239 | "l", 240 | "pwd", 241 | "clear", 242 | "exit", 243 | "which", 244 | "man", 245 | ] 246 | 247 | [keys] 248 | # Defaults to true. If disabled, using the up/down key won't exit the TUI when scrolled past the first/last entry. 249 | scroll_exits = false # Keep browsing 250 | # Defaults to true. The left arrow key will exit the TUI when scrolling before the first character 251 | exit_past_line_start = false 252 | # Defaults to true. The right arrow key performs the same functionality as Tab and copies the selected line to the command line to be modified. 253 | accept_past_line_end = true 254 | 255 | [sync] 256 | # Enable sync v2 by default 257 | # This ensures that sync v2 is enabled for new installs only 258 | # In a later release it will become the default across the board 259 | records = true 260 | 261 | [preview] 262 | ## which preview strategy to use to calculate the preview height (respects max_preview_height). 263 | ## possible values: auto, static 264 | ## auto: length of the selected command. 265 | ## static: length of the longest command stored in the history. 266 | ## fixed: use max_preview_height as fixed height. 267 | strategy = "auto" 268 | 269 | [daemon] 270 | ## Enables using the daemon to sync. Requires the daemon to be running in the background. Start it with `atuin daemon` 271 | enabled = false # Enable if you want background sync 272 | ## How often the daemon should sync in seconds 273 | sync_frequency = 300 274 | ## The path to the unix socket used by the daemon (on unix systems) 275 | ## linux/mac: ~/.local/share/atuin/atuin.sock 276 | ## windows: Not Supported 277 | # socket_path = "~/.local/share/atuin/atuin.sock" 278 | ## Use systemd socket activation rather than opening the given path (the path must still be correct for the client) 279 | ## linux: false 280 | ## mac/windows: Not Supported 281 | # systemd_socket = false 282 | ## The port that should be used for TCP on non unix systems 283 | # tcp_port = 8889 284 | 285 | [theme] 286 | ## Color theme to use for rendering in the terminal. 287 | ## There are some built-in themes, including the base theme ("default"), 288 | ## "autumn" and "marine". You can add your own themes to the "./themes" subdirectory of your 289 | ## Atuin config (or ATUIN_THEME_DIR, if provided) as TOML files whose keys should be one or 290 | ## more of AlertInfo, AlertWarn, AlertError, Annotation, Base, Guidance, Important, and 291 | ## the string values as lowercase entries from this list: 292 | ## https://ogeon.github.io/docs/palette/master/palette/named/index.html 293 | ## If you provide a custom theme file, it should be called "NAME.toml" and the theme below 294 | ## should be the stem, i.e. `theme = "NAME"` for your chosen NAME. 295 | name = "catppuccin-macchiato-mauve" # Smooth Catppuccin vibes 296 | ## Whether the theme manager should output normal or extra information to help fix themes. 297 | ## Boolean, true or false. If unset, left up to the theme manager. 298 | # debug = true 299 | 300 | [search] 301 | ## The list of enabled filter modes, in order of priority. 302 | ## The "workspace" mode is skipped when not in a workspace or workspaces = false. 303 | ## Default filter mode can be overridden with the filter_mode setting. 304 | filters = [ "workspace", "directory", "global", "host", "session" ] # Smart context awareness 305 | -------------------------------------------------------------------------------- /zellij/config.kdl: -------------------------------------------------------------------------------- 1 | // 2 | // THIS FILE WAS AUTOGENERATED BY ZELLIJ, THE PREVIOUS FILE AT THIS LOCATION WAS COPIED TO: /Users/joel/.config/zellij/config.kdl.bak 3 | // 4 | 5 | keybinds clear-defaults=true { 6 | locked { 7 | bind "Ctrl g" { SwitchToMode "normal"; } 8 | } 9 | pane { 10 | bind "Left" { MoveFocus "left"; } 11 | bind "Down" { MoveFocus "down"; } 12 | bind "Up" { MoveFocus "up"; } 13 | bind "Right" { MoveFocus "right"; } 14 | bind "c" { SwitchToMode "renamepane"; PaneNameInput 0; } 15 | bind "d" { NewPane "down"; SwitchToMode "normal"; } 16 | bind "e" { TogglePaneEmbedOrFloating; SwitchToMode "normal"; } 17 | bind "f" { ToggleFocusFullscreen; SwitchToMode "normal"; } 18 | bind "h" { MoveFocus "left"; } 19 | bind "j" { MoveFocus "down"; } 20 | bind "k" { MoveFocus "up"; } 21 | bind "l" { MoveFocus "right"; } 22 | bind "n" { NewPane; SwitchToMode "normal"; } 23 | bind "p" { SwitchFocus; } 24 | bind "Ctrl p" { SwitchToMode "normal"; } 25 | bind "r" { NewPane "right"; SwitchToMode "normal"; } 26 | bind "w" { ToggleFloatingPanes; SwitchToMode "normal"; } 27 | bind "z" { TogglePaneFrames; SwitchToMode "normal"; } 28 | } 29 | tab { 30 | bind "Left" { GoToPreviousTab; } 31 | bind "Down" { GoToNextTab; } 32 | bind "Up" { GoToPreviousTab; } 33 | bind "Right" { GoToNextTab; } 34 | bind "1" { GoToTab 1; SwitchToMode "normal"; } 35 | bind "2" { GoToTab 2; SwitchToMode "normal"; } 36 | bind "3" { GoToTab 3; SwitchToMode "normal"; } 37 | bind "4" { GoToTab 4; SwitchToMode "normal"; } 38 | bind "5" { GoToTab 5; SwitchToMode "normal"; } 39 | bind "6" { GoToTab 6; SwitchToMode "normal"; } 40 | bind "7" { GoToTab 7; SwitchToMode "normal"; } 41 | bind "8" { GoToTab 8; SwitchToMode "normal"; } 42 | bind "9" { GoToTab 9; SwitchToMode "normal"; } 43 | bind "[" { BreakPaneLeft; SwitchToMode "normal"; } 44 | bind "]" { BreakPaneRight; SwitchToMode "normal"; } 45 | bind "b" { BreakPane; SwitchToMode "normal"; } 46 | bind "h" { GoToPreviousTab; } 47 | bind "j" { GoToNextTab; } 48 | bind "k" { GoToPreviousTab; } 49 | bind "l" { GoToNextTab; } 50 | bind "n" { NewTab; SwitchToMode "normal"; } 51 | bind "r" { SwitchToMode "renametab"; TabNameInput 0; } 52 | bind "s" { ToggleActiveSyncTab; SwitchToMode "normal"; } 53 | bind "Ctrl t" { SwitchToMode "normal"; } 54 | bind "x" { CloseTab; SwitchToMode "normal"; } 55 | bind "Tab" { ToggleTab; } 56 | } 57 | resize { 58 | bind "Left" { Resize "Increase left"; } 59 | bind "Down" { Resize "Increase down"; } 60 | bind "Up" { Resize "Increase up"; } 61 | bind "Right" { Resize "Increase right"; } 62 | bind "+" { Resize "Increase"; } 63 | bind "-" { Resize "Decrease"; } 64 | bind "=" { Resize "Increase"; } 65 | bind "H" { Resize "Decrease left"; } 66 | bind "J" { Resize "Decrease down"; } 67 | bind "K" { Resize "Decrease up"; } 68 | bind "L" { Resize "Decrease right"; } 69 | bind "h" { Resize "Increase left"; } 70 | bind "j" { Resize "Increase down"; } 71 | bind "k" { Resize "Increase up"; } 72 | bind "l" { Resize "Increase right"; } 73 | bind "Ctrl n" { SwitchToMode "normal"; } 74 | } 75 | move { 76 | bind "Left" { MovePane "left"; } 77 | bind "Down" { MovePane "down"; } 78 | bind "Up" { MovePane "up"; } 79 | bind "Right" { MovePane "right"; } 80 | bind "h" { MovePane "left"; } 81 | bind "Ctrl h" { SwitchToMode "normal"; } 82 | bind "j" { MovePane "down"; } 83 | bind "k" { MovePane "up"; } 84 | bind "l" { MovePane "right"; } 85 | bind "n" { MovePane; } 86 | bind "p" { MovePaneBackwards; } 87 | bind "Tab" { MovePane; } 88 | } 89 | scroll { 90 | bind "Alt h" { MoveFocusOrTab "left"; SwitchToMode "normal"; } 91 | bind "Alt j" { MoveFocus "down"; SwitchToMode "normal"; } 92 | bind "Alt k" { MoveFocus "up"; SwitchToMode "normal"; } 93 | bind "Alt l" { MoveFocusOrTab "right"; SwitchToMode "normal"; } 94 | bind "e" { EditScrollback; SwitchToMode "normal"; } 95 | bind "s" { SwitchToMode "entersearch"; SearchInput 0; } 96 | } 97 | search { 98 | bind "c" { SearchToggleOption "CaseSensitivity"; } 99 | bind "n" { Search "down"; } 100 | bind "o" { SearchToggleOption "WholeWord"; } 101 | bind "p" { Search "up"; } 102 | bind "w" { SearchToggleOption "Wrap"; } 103 | } 104 | session { 105 | bind "c" { 106 | LaunchOrFocusPlugin "configuration" { 107 | floating true 108 | move_to_focused_tab true 109 | } 110 | SwitchToMode "normal" 111 | } 112 | bind "Ctrl o" { SwitchToMode "normal"; } 113 | bind "p" { 114 | LaunchOrFocusPlugin "plugin-manager" { 115 | floating true 116 | move_to_focused_tab true 117 | } 118 | SwitchToMode "normal" 119 | } 120 | bind "w" { 121 | LaunchOrFocusPlugin "session-manager" { 122 | floating true 123 | move_to_focused_tab true 124 | } 125 | SwitchToMode "normal" 126 | } 127 | } 128 | shared_except "locked" { 129 | bind "Alt +" { Resize "Increase"; } 130 | bind "Alt -" { Resize "Decrease"; } 131 | bind "Alt =" { Resize "Increase"; } 132 | bind "Alt [" { PreviousSwapLayout; } 133 | bind "Alt ]" { NextSwapLayout; } 134 | bind "Alt f" { ToggleFloatingPanes; } 135 | bind "Ctrl g" { SwitchToMode "locked"; } 136 | bind "Alt i" { MoveTab "left"; } 137 | bind "Alt n" { NewPane; } 138 | bind "Alt o" { MoveTab "right"; } 139 | bind "Ctrl q" { Quit; } 140 | // Additional convenient bindings 141 | bind "Alt 1" { GoToTab 1; } 142 | bind "Alt 2" { GoToTab 2; } 143 | bind "Alt 3" { GoToTab 3; } 144 | bind "Alt 4" { GoToTab 4; } 145 | bind "Alt 5" { GoToTab 5; } 146 | bind "Alt 6" { GoToTab 6; } 147 | bind "Alt 7" { GoToTab 7; } 148 | bind "Alt 8" { GoToTab 8; } 149 | bind "Alt 9" { GoToTab 9; } 150 | bind "Alt w" { CloseTab; } 151 | bind "Alt r" { SwitchToMode "renametab"; TabNameInput 0; } 152 | } 153 | shared_except "locked" "move" { 154 | bind "Alt m" { SwitchToMode "move"; } 155 | } 156 | shared_except "locked" "session" { 157 | bind "Ctrl o" { SwitchToMode "session"; } 158 | } 159 | shared_except "locked" "scroll" { 160 | bind "Alt h" { MoveFocusOrTab "left"; } 161 | bind "Alt j" { MoveFocus "down"; } 162 | bind "Alt k" { MoveFocus "up"; } 163 | bind "Alt l" { MoveFocusOrTab "right"; } 164 | } 165 | shared_except "locked" "scroll" "search" "tmux" { 166 | bind "Ctrl b" { SwitchToMode "tmux"; } 167 | } 168 | shared_except "locked" "scroll" "search" { 169 | bind "Alt s" { SwitchToMode "scroll"; } 170 | } 171 | shared_except "locked" "tab" { 172 | bind "Ctrl t" { SwitchToMode "tab"; } 173 | } 174 | shared_except "locked" "pane" { 175 | bind "Ctrl p" { SwitchToMode "pane"; } 176 | } 177 | shared_except "locked" "resize" { 178 | bind "Ctrl n" { SwitchToMode "resize"; } 179 | } 180 | shared_except "normal" "locked" "entersearch" { 181 | bind "Enter" { SwitchToMode "normal"; } 182 | } 183 | shared_except "normal" "locked" "entersearch" "renametab" "renamepane" { 184 | bind "Tab" { ToggleTab; } 185 | } 186 | shared_among "pane" "tmux" { 187 | bind "x" { CloseFocus; SwitchToMode "normal"; } 188 | } 189 | shared_among "scroll" "search" { 190 | bind "PageDown" { PageScrollDown; } 191 | bind "PageUp" { PageScrollUp; } 192 | bind "Left" { PageScrollUp; } 193 | bind "Down" { ScrollDown; } 194 | bind "Up" { ScrollUp; } 195 | bind "Right" { PageScrollDown; } 196 | bind "Ctrl b" { PageScrollUp; } 197 | bind "Ctrl c" { ScrollToBottom; SwitchToMode "normal"; } 198 | bind "d" { HalfPageScrollDown; } 199 | bind "Ctrl f" { PageScrollDown; } 200 | bind "h" { PageScrollUp; } 201 | bind "j" { ScrollDown; } 202 | bind "k" { ScrollUp; } 203 | bind "l" { PageScrollDown; } 204 | bind "Ctrl s" { SwitchToMode "normal"; } 205 | bind "u" { HalfPageScrollUp; } 206 | } 207 | entersearch { 208 | bind "Ctrl c" { SwitchToMode "scroll"; } 209 | bind "Esc" { SwitchToMode "scroll"; } 210 | bind "Enter" { SwitchToMode "search"; } 211 | } 212 | renametab { 213 | bind "Esc" { UndoRenameTab; SwitchToMode "tab"; } 214 | } 215 | shared_among "renametab" "renamepane" { 216 | bind "Ctrl c" { SwitchToMode "normal"; } 217 | } 218 | renamepane { 219 | bind "Esc" { UndoRenamePane; SwitchToMode "pane"; } 220 | } 221 | shared_among "session" "tmux" { 222 | bind "d" { Detach; } 223 | } 224 | tmux { 225 | bind "Left" { MoveFocus "left"; SwitchToMode "normal"; } 226 | bind "Down" { MoveFocus "down"; SwitchToMode "normal"; } 227 | bind "Up" { MoveFocus "up"; SwitchToMode "normal"; } 228 | bind "Right" { MoveFocus "right"; SwitchToMode "normal"; } 229 | bind "Space" { NextSwapLayout; } 230 | bind "\"" { NewPane "down"; SwitchToMode "normal"; } 231 | bind "%" { NewPane "right"; SwitchToMode "normal"; } 232 | bind "," { SwitchToMode "renametab"; } 233 | bind "[" { SwitchToMode "scroll"; } 234 | bind "Ctrl b" { Write 2; SwitchToMode "normal"; } 235 | bind "c" { NewTab; SwitchToMode "normal"; } 236 | bind "h" { MoveFocus "left"; SwitchToMode "normal"; } 237 | bind "j" { MoveFocus "down"; SwitchToMode "normal"; } 238 | bind "k" { MoveFocus "up"; SwitchToMode "normal"; } 239 | bind "l" { MoveFocus "right"; SwitchToMode "normal"; } 240 | bind "n" { GoToNextTab; SwitchToMode "normal"; } 241 | bind "o" { FocusNextPane; } 242 | bind "p" { GoToPreviousTab; SwitchToMode "normal"; } 243 | bind "z" { ToggleFocusFullscreen; SwitchToMode "normal"; } 244 | } 245 | } 246 | 247 | // Plugin aliases - can be used to change the implementation of Zellij 248 | // changing these requires a restart to take effect 249 | plugins { 250 | compact-bar location="zellij:compact-bar" 251 | configuration location="zellij:configuration" 252 | filepicker location="zellij:strider" { 253 | cwd "/" 254 | } 255 | plugin-manager location="zellij:plugin-manager" 256 | session-manager location="zellij:session-manager" 257 | status-bar location="zellij:status-bar" 258 | strider location="zellij:strider" 259 | tab-bar location="zellij:tab-bar" 260 | welcome-screen location="zellij:session-manager" { 261 | welcome_screen true 262 | } 263 | forgot location="zellij:forgot" 264 | datetime location="zellij:datetime" 265 | mem location="zellij:mem" 266 | } 267 | 268 | // Plugins to load in the background when a new session starts 269 | // eg. "file:/path/to/my-plugin.wasm" 270 | // eg. "https://example.com/my-plugin.wasm" 271 | load_plugins { 272 | } 273 | 274 | // Use a simplified UI without special fonts (arrow glyphs) 275 | // Options: 276 | // - true 277 | // - false (Default) 278 | // 279 | simplified_ui false // Disable for better aesthetics with proper fonts 280 | 281 | // Choose the theme that is specified in the themes section. 282 | // Default: default 283 | // 284 | theme "catppuccin-macchiato" 285 | 286 | // Choose the base input mode of zellij. 287 | // Default: normal 288 | // 289 | default_mode "normal" 290 | 291 | // Choose the path to the default shell that zellij will use for opening new panes 292 | // Default: $SHELL 293 | // 294 | // default_shell "fish" 295 | 296 | // Choose the path to override cwd that zellij will use for opening new panes 297 | // 298 | // default_cwd "/tmp" 299 | 300 | // The name of the default layout to load on startup 301 | // Default: "default" 302 | // 303 | default_layout "default" 304 | 305 | // The folder in which Zellij will look for layouts 306 | // (Requires restart) 307 | // 308 | layout_dir "/Users/joel/.config/zellij/layouts" 309 | 310 | // The folder in which Zellij will look for themes 311 | // (Requires restart) 312 | // 313 | theme_dir "/Users/joel/.config/zellij/themes" 314 | 315 | // Toggle enabling the mouse mode. 316 | // On certain configurations, or terminals this could 317 | // potentially interfere with copying text. 318 | // Options: 319 | // - true (default) 320 | // - false 321 | // 322 | // mouse_mode false 323 | 324 | // Toggle having pane frames around the panes 325 | // Options: 326 | // - true (default, enabled) 327 | // - false 328 | // 329 | pane_frames true // Enable for better visual separation 330 | 331 | // When attaching to an existing session with other users, 332 | // should the session be mirrored (true) 333 | // or should each user have their own cursor (false) 334 | // (Requires restart) 335 | // Default: false 336 | // 337 | // mirror_session true 338 | 339 | // Choose what to do when zellij receives SIGTERM, SIGINT, SIGQUIT or SIGHUP 340 | // eg. when terminal window with an active zellij session is closed 341 | // (Requires restart) 342 | // Options: 343 | // - detach (Default) 344 | // - quit 345 | // 346 | // on_force_close "quit" 347 | 348 | // Configure the scroll back buffer size 349 | // This is the number of lines zellij stores for each pane in the scroll back 350 | // buffer. Excess number of lines are discarded in a FIFO fashion. 351 | // (Requires restart) 352 | // Valid values: positive integers 353 | // Default value: 10000 354 | // 355 | scroll_buffer_size 1000000 356 | 357 | // Provide a command to execute when copying text. The text will be piped to 358 | // the stdin of the program to perform the copy. This can be used with 359 | // terminal emulators which do not support the OSC 52 ANSI control sequence 360 | // that will be used by default if this option is not set. 361 | // Examples: 362 | // 363 | // copy_command "xclip -selection clipboard" // x11 364 | // copy_command "wl-copy" // wayland 365 | // copy_command "pbcopy" // osx 366 | // 367 | copy_command "pbcopy" 368 | 369 | // Choose the destination for copied text 370 | // Allows using the primary selection buffer (on x11/wayland) instead of the system clipboard. 371 | // Does not apply when using copy_command. 372 | // Options: 373 | // - system (default) 374 | // - primary 375 | // 376 | // copy_clipboard "primary" 377 | 378 | // Enable automatic copying (and clearing) of selection when releasing mouse 379 | // Default: true 380 | // 381 | copy_on_select true 382 | 383 | // Path to the default editor to use to edit pane scrollbuffer 384 | // Default: $EDITOR or $VISUAL 385 | // scrollback_editor "/usr/bin/vim" 386 | 387 | // A fixed name to always give the Zellij session. 388 | // Consider also setting `attach_to_session true,` 389 | // otherwise this will error if such a session exists. 390 | // Default: 391 | // 392 | // session_name "My singleton session" 393 | 394 | // When `session_name` is provided, attaches to that session 395 | // if it is already running or creates it otherwise. 396 | // Default: false 397 | // 398 | attach_to_session true 399 | 400 | // Toggle between having Zellij lay out panes according to a predefined set of layouts whenever possible 401 | // Options: 402 | // - true (default) 403 | // - false 404 | // 405 | // auto_layout false 406 | 407 | // Whether sessions should be serialized to the cache folder (including their tabs/panes, cwds and running commands) so that they can later be resurrected 408 | // Options: 409 | // - true (default) 410 | // - false 411 | // 412 | // session_serialization false 413 | 414 | // Whether pane viewports are serialized along with the session, default is false 415 | // Options: 416 | // - true 417 | // - false (default) 418 | // 419 | serialize_pane_viewport true 420 | 421 | // Scrollback lines to serialize along with the pane viewport when serializing sessions, 0 422 | // defaults to the scrollback size. If this number is higher than the scrollback size, it will 423 | // also default to the scrollback size. This does nothing if `serialize_pane_viewport` is not true. 424 | // 425 | scrollback_lines_to_serialize 100000 426 | 427 | // Enable or disable the rendering of styled and colored underlines (undercurl). 428 | // May need to be disabled for certain unsupported terminals 429 | // (Requires restart) 430 | // Default: true 431 | // 432 | // styled_underlines false 433 | 434 | // How often in seconds sessions are serialized 435 | // 436 | serialization_interval 600 437 | 438 | // Enable or disable writing of session metadata to disk (if disabled, other sessions might not know 439 | // metadata info on this session) 440 | // (Requires restart) 441 | // Default: false 442 | // 443 | // disable_session_metadata false 444 | 445 | // Enable or disable support for the enhanced Kitty Keyboard Protocol (the host terminal must also support it) 446 | // (Requires restart) 447 | // Default: true (if the host terminal supports it) 448 | // 449 | // support_kitty_keyboard_protocol false 450 | 451 | // UI Configuration 452 | ui { 453 | pane_frames { 454 | rounded_corners true 455 | hide_session_name false 456 | } 457 | } 458 | 459 | // Add this to handle Esc consistently across all modes except locked 460 | shared_except "normal" "locked" { 461 | bind "Esc" { SwitchToMode "normal"; } 462 | } 463 | 464 | // Keep the specific Esc handlers for special cases 465 | renametab { 466 | bind "Esc" { UndoRenameTab; SwitchToMode "tab"; } 467 | } 468 | 469 | renamepane { 470 | bind "Esc" { UndoRenamePane; SwitchToMode "pane"; } 471 | } 472 | 473 | entersearch { 474 | bind "Esc" { SwitchToMode "scroll"; } 475 | } -------------------------------------------------------------------------------- /karabiner/karabiner.edn: -------------------------------------------------------------------------------- 1 | {; 2 | :default true 3 | :alone 500 4 | :delay 200 5 | :held 500 6 | :simlayer-threshold 200 7 | 8 | ; aliases for modifier keys 9 | :modifiers {:super-hyper [:command :shift :control :option :fn] 10 | :hyper [:command :shift :control :option] 11 | :cos [:command :shift :option] 12 | :cst [:command :shift :control] 13 | :co [:command :option] 14 | :cs [:command :shift] 15 | :ct [:command :control] 16 | :to [:control :option] 17 | :ts [:control :shift] 18 | :os [:option :shift] 19 | ; 20 | } 21 | 22 | 23 | :froms {;alias 24 | :delete {:key :delete_or_backspace} 25 | :return {:key :return_or_enter} 26 | :tilde {:key :grave_accent_and_tilde} 27 | ;qw 28 | } 29 | 30 | :tos {; 31 | :shift_click {:pkey :button1 :modi :left_shift} 32 | 33 | :delete {:key :delete_or_backspace} 34 | :return {:key :return_or_enter} 35 | :tilde {:key :grave_accent_and_tilde} 36 | 37 | :annotate_screen {:key :a :modi :control} 38 | :annotate_screen_more {:key :a :modi :co} 39 | 40 | 41 | 42 | ;shortcuts 43 | :autocomplete {:key :spacebar :modi :control} ;!Tspacebar 44 | :command_palette {:key :p :modi :cs} 45 | 46 | :capture_screenshot {:key :4 :modi :cs} 47 | :record_screen {:key :6 :modi :cs} 48 | :cursor_find_match {:key :d :modi :command} 49 | :cursor_select_all {:key :l :modi :cs} 50 | :cursor_above {:key :up_arrow :modi :co} 51 | :cursor_below {:key :down_arrow :modi :co} 52 | :acejump {:key :j :modi :cos} 53 | :acejump_line {:key :l :modi :cos} 54 | :acejump_selection {:key :s :modi :cos} 55 | :acejump_multi {:key :m :modi :cos} 56 | 57 | :close_all [{:key :k :modi :command} {:key :w}] 58 | :close_others [{:key :t :modi :co}] 59 | :developer_tools [{:key :i :modi :co}] 60 | 61 | :delete_line {:key :k :modi :cs} ;!CSk 62 | 63 | :find_in_project {:key :f :modi :cs} ;!CSf 64 | 65 | :focus_git {:key :g :modi :ts} ;!TSg 66 | :focus_editor {:key :e :modi :control} 67 | :focus_explorer {:key :e :modi :cs} ;:!CSOe 68 | :focus_terminal {:key :j :modi :command} 69 | :start_debugger {:key :f5} 70 | :restart_debugger {:key :f5 :modi :cs} 71 | 72 | :go_to_references {:key :f12 :modi :shift} 73 | :go_to_symbol {:key :o :modi :cs} 74 | :go_to_symbol_in_workspace {:key :o :modi :cos} 75 | :search_everywhere {:key :p :modi :co} 76 | :go_to_implementations {:key :f12 :modi :command} 77 | :go_to_definition {:key :f12} 78 | :go_to_line {:key :g :modi :control} 79 | :go_to_prev_problem {:key :f8 :modi :shift} 80 | :go_to_next_problem {:key :f8} 81 | :go_home {:key :up_arrow :modi :command} 82 | :go_end {:key :down_arrow :modi :command} 83 | 84 | :new_terminal {:key :grave_accent_and_tilde :modi :ts}; !TS` 85 | 86 | :open_next_editor {:key :right_arrow :modi :co} 87 | :open_prev_editor {:key :left_arrow :modi :co} 88 | :focus_next_editor_group {:key :f16 :modi :option} 89 | :focus_prev_editor_group {:key :f16 :modi :os} 90 | 91 | :peek_definition {:key :f12 :modi :option} 92 | :peek_implementations {:key :f12 :modi :cs} 93 | :peek_declaration {:key :f19 :modi :control} 94 | :peek_references {:key :f19 :modi :command} 95 | :peek_type {:key :f19 :modi :shift} 96 | 97 | :go_back {:key :hyphen :modi :control} 98 | :go_forward {:key :hyphen :modi :ts} 99 | 100 | :replace {:key :f :modi :co} 101 | :rename {:key :f2} 102 | 103 | :split_window {:key :backslash :modi :command}; !Cbackslash 104 | 105 | :toggle_sidebar {:key :b :modi :command} ;!Cb 106 | 107 | :expand_selection {:key :right_arrow :modi :cst} 108 | :shrink_selection {:key :left_arrow :modi :cst} 109 | 110 | :go_to_file {:key :p :modi :command} 111 | :insert_line_below {:key :return_or_enter :modi :command} ;!Creturn_or_enter 112 | :insert_line_above {:key :return_or_enter :modi :cs} ;!Creturn_or_enter 113 | :wrap_emmet {:key :p :modi :hyper} 114 | 115 | ;named symbols 116 | :open_brace {:key :open_bracket :modi :shift} 117 | :close_brace {:key :close_bracket :modi :shift} 118 | 119 | :open_paren {:key :9 :modi :shift} 120 | :close_paren {:key :0 :modi :shift} 121 | 122 | :less_than {:key :comma :modi :shift} 123 | :greater_than {:key :period :modi :shift} 124 | 125 | :emoji_picker {:key :spacebar :modi :ct} ;!CTspacebar 126 | 127 | :open_1password {:key :backslash :modi :command} ;!OCbackslash 128 | 129 | :take_screenshot {:key :6 :modi :cs} ;!CS6 130 | 131 | :toggle_screen_brush {:key :tab :modi :option} ;!Otab 132 | 133 | ;chrome 134 | :open_dev_tools {:key :i :modi :co} ;:!COl 135 | :chrome_full_screen {:key :f :modi :ct} 136 | :focus_omnibar {:key :l :modi :command} 137 | :chrome_go_back {:key :open_bracket :modi :command} 138 | :chrome_go_forward {:key :close_bracket :modi :command} 139 | 140 | 141 | ;ableton 142 | :add_midi_clip {:key :m :modi :cs};!CSm 143 | :add_midi_track {:key :t :modi :cs} 144 | :loop_selection {:key :l :modi :command} 145 | :toggle_clip_device_view {:key :tab :modi :shift} 146 | :narrow_grid {:key :1 :modi :command} 147 | :widen_grid {:key :2 :modi :command} 148 | :snap_to_grid {:key :4 :modi :command} 149 | :split_clip {:key :e :modi :command} 150 | ; 151 | 152 | :display_layout_1 {:key :1 :modi :hyper} 153 | :display_layout_2 {:key :1 :modi :hyper} 154 | 155 | ;snippets 156 | } 157 | 158 | :templates {; 159 | :beep "osascript -e 'beep'" 160 | :beep2 "osascript -e 'beep 2'" 161 | :new-note "osascript -e 'tell application id \"com.runningwithcrayons. 162 | \" to run trigger \"new-note\" in workflow \"com.johnlindquist.new-note\" with argument \"\"'" 163 | :new-blog "osascript -e 'tell application id \"com.runningwithcrayons.Alfred\" to run trigger \"new-blog\" in workflow \"com.johnlindquist.new-blog\" with argument \"\"'" 164 | :alfred "osascript -e 'tell application \"Alfred 4\" to run trigger \"%s\" in workflow \"%s\" with argument \"%s\"'" 165 | :code-project "~/.kenv/bin/code-project \"%s\"" 166 | :delay "osascript -e 'delay \"%s\"'" 167 | :km "osascript -e 'tell application \"Keyboard Maestro Engine\" to do script \"%s\"'" 168 | :type "osascript -e 'tell application \"System Events\" to keystroke \"%s\"'" 169 | :type-secret "osascript -e ' 170 | set out to do shell script \"security find-generic-password -a $USER -s %s -w\" 171 | 172 | tell application \"System Events\" to keystroke out 173 | '" 174 | :kit "~/.kit/kar \"%s\"" 175 | :focus "~/.kit/kar focus \"%s\"" 176 | :launch "osascript -e 'tell application \"%s\" to activate'" 177 | :open-chrome ". ~/.kenv/bin/focus-tab %s" 178 | :open "open \"%s\"" 179 | :open-a "open -a '%s'" 180 | :paste "~/.simple/bin/paste-input %s" 181 | :restream "osascript -e 'tell application \"Restream Chat\" to activate'" 182 | :zsh "zsh ~/.zfunc/'%s'" 183 | :print "osascript -e ' 184 | set the clipboard to do shell script \"echo $PLEASE\" 185 | tell application \"System Events\" 186 | keystroke \"v\" using command down 187 | end tell 188 | '" 189 | :modify "~/.simple/bin/modify --%s" 190 | :pad "~/.simple/bin/pad" 191 | :test "osascript -e 'say \"poop\"'" 192 | :datamuse "osascript -e ' 193 | tell application id \"com.runningwithcrayons.Alfred\" to run trigger \"datamuse\" in workflow \"com.johnlindquist.datamuse\" with argument \"%s\" 194 | '" 195 | ; 196 | } 197 | 198 | :applications {; 199 | :ableton ["com.ableton.live"] 200 | :chrome ["com.google.Chrome"] 201 | :code ["com.microsoft.VSCode","com.todesktop.230313mzl4w4u92"] 202 | :fcp ["com.apple.FinalCut"] 203 | :miro ["com.electron.realtimeboard"] 204 | :screenflow ["net.telestream.screenflow10"] 205 | :slack ["com.tinyspeck.slackmacgap"] 206 | ;; :webstorm ["com.jetbrains.Webstorm"] 207 | ; 208 | } 209 | ; Layers Are Typically "Thumb Keys" or "Pinky Keys" 210 | :layers {; 211 | :caps_lock-mode {:key :caps_lock :alone 212 | {:key :escape}} 213 | :escape-mode {:key :escape nil [;in case a mode gets stuck 😬 214 | {:set ["fn-mode" 0]} 215 | {:set ["opt-mode" 0]} 216 | {:set ["shift-opt-mode" 0]} 217 | {:set ["movement-mode" 0]} 218 | {:set ["cursor-mode" 0]} 219 | {:set ["delete-mode" 0]} 220 | {:set ["editor-mode" 0]} 221 | {:set ["snippet-mode" 0]}]} 222 | :f23-mode {:key :f23 :alone {:key :vk_none}} 223 | :launch-mode {:key :f24 :alone {:key :spacebar :modi :left_option}} 224 | :non-mode {:key :non_us_backslash :alone {:key :non_us_backslash}} 225 | :num-mode {:key :keypad_num_lock :alone {:key :vk_none}} 226 | :shift-mode {:key :shift} 227 | :tab-mode {:key :tab} 228 | 229 | :tilde-mode {:key :grave_accent_and_tilde :alone {:key :grave_accent_and_tilde}} 230 | 231 | 232 | 233 | 234 | ; 235 | } 236 | :simlayers {; 237 | ;top row 238 | :zero-mode {:key :0} 239 | :quick-mode {:key :q} 240 | :close-mode {:key :w} 241 | :finder-mode {:key :e} 242 | :peek-mode {:key :r} 243 | :go-mode {:key :t} 244 | :t-mode {:key :t} 245 | :code-mode {:key :p} 246 | :backslash-mode {:key :backslash} ;unused 🤔 247 | ;end top row 248 | 249 | ;begin homerow simlayer 250 | :fn-mode {:key :hyphen :alone {:key :hyphen}} 251 | :opt-mode {:key :a} 252 | :shift-opt-mode {:key :s} 253 | :shift-mode {:key :d} 254 | :movement-mode {:key :f} 255 | :cursor-mode {:key :g} 256 | :delete-mode {:key :j} 257 | :editor-mode {:key :k} 258 | :i-mode {:key :i} 259 | :period-mode {:key :period} 260 | :semicolon-mode {:key :semicolon} 261 | :l-mode {:key :l} 262 | :kit-mode {:key :n} 263 | :open-mode {:key :semicolon} 264 | :snippet-mode {:key :quote} 265 | ;end homerow 266 | 267 | ;begin bottom row 268 | :emoji-mode {:key :z} 269 | :command-mode {:key :c} 270 | :modify-mode {:key :period} 271 | 272 | :slash-mode {:key :slash} 273 | ;end bottom row 274 | 275 | 276 | ;begin special keys 277 | :equals-mode {:key :equal_sign} 278 | :spacebar-mode {:key :spacebar} 279 | :password-mode {:key :quote :condi :shift-mode} 280 | ;end special keys 281 | 282 | 283 | 284 | 285 | 286 | 287 | ; 288 | } 289 | :devices {;; Note - I'm currently using a Kinesis Advantage keyboard for my defaults 290 | ;; and my macbook hasn't left my desk in a looooooong time... 291 | ;; :macbook [{:product_id 832 :vendor_id 1452}] 292 | 293 | :kinesis360 [{:product_id 864 :vendor_id 10730}] 294 | :apple [{:product_id 832 :vendor_id 1452}]} 295 | 296 | :main [; 297 | 298 | {:des "apple" 299 | :rules [:apple 300 | [:slash :left_command nil {:alone :slash}] 301 | [:period :left_option nil {:alone :period}] 302 | [:left_shift :left_shift nil {:alone :delete}] 303 | [:right_shift :right_shift nil {:alone :delete_forward}] 304 | 305 | 306 | ; 307 | ]} 308 | 309 | 310 | {:des "Displays" 311 | ; 312 | :rules [:zero-mode 313 | ; 314 | [:1 :display_layout_1] 315 | [:2 :display_layout_2] 316 | [:3 :!CSTO3] 317 | [:4 :!CSTO4] 318 | ; 319 | ]} 320 | 321 | {:des "close" 322 | :rules [:close-mode 323 | ;[:m [:modify "wrap-markdown-link"]] 324 | ;[:e :wrap_emmet] 325 | [:condi :code :close-mode] 326 | [:a :close_all] 327 | [:o :close_others] 328 | 329 | [:condi :chrome :close-mode] 330 | [:a :close_all] 331 | [:o :close_others] 332 | ; 333 | ]} 334 | {:des "finder" 335 | :rules [:finder-mode 336 | [:a "open /Applications"] 337 | [:d "open ~/Downloads"] 338 | [:h "open ~"] 339 | 340 | ; 341 | ]} 342 | {:des "peek mode" 343 | :rules [:peek-mode 344 | [:h :peek_definition] 345 | [:e :peek_implementations] 346 | [:n :peek_references] 347 | [:i :peek_declaration] 348 | [:o :peek_type]]} 349 | 350 | {:des "quick" 351 | :rules [:quick-mode 352 | [:w :annotate_screen] 353 | [:e :annotate_screen_more]]} 354 | 355 | 356 | {:des "go" 357 | :rules [:go-mode 358 | [:r :go_to_references]; 359 | [:w :go_to_symbol_in_workspace]; 360 | [:s :go_to_symbol]; 361 | [:h :search_everywhere]; 362 | [:i :go_to_implementations]; 363 | [:n :go_to_symbol]; g,d is impossible in colemak 364 | [:o :go_to_definition]; g,d is impossible in colemak 365 | [:l :go_to_line]; g,d is impossible in colemak 366 | [:m :go_to_prev_problem]; g,d is impossible in colemak 367 | [:comma :go_to_next_problem]; g,d is impossible in colemak 368 | 369 | ; 370 | ]} 371 | 372 | ;begin homerow 373 | {:des "control" 374 | :rules [:fn-mode 375 | [:##d :left_shift] 376 | 377 | 378 | [:##h :!Fleft_arrow] 379 | [:##j :!Fdown_arrow] 380 | [:##k :!Fup_arrow] 381 | [:##l :!Fright_arrow] 382 | ; ; 383 | ]} 384 | 385 | {:des "opt" 386 | :rules [:opt-mode 387 | ;; [:##y :home] 388 | 389 | ;; [:##o :end] 390 | 391 | 392 | [:##h :!Oleft_arrow] 393 | [:##j :!Odown_arrow] 394 | [:##k :!Oup_arrow] 395 | [:##l :!Oright_arrow] 396 | 397 | ; 398 | ]} 399 | {:des "shift-opt" 400 | :rules [:shift-opt-mode 401 | [:##h :!OSleft_arrow] 402 | [:##j :!OSdown_arrow] 403 | [:##k :!OSup_arrow] 404 | [:##l :!OSright_arrow] 405 | 406 | [:##spacebar {:pkey :button1 :modi :left_command}] 407 | [:##left_shift :##button2] 408 | 409 | ;; [:condi :chrome] 410 | ;; [:n :chrome_go_back] 411 | ;; [:e :chrome_go_forward] 412 | 413 | ; 414 | ]} 415 | 416 | {:des "shift" 417 | :rules [:shift-mode 418 | [:##y :!CSleft_arrow] 419 | [:##o :!CSright_arrow] 420 | 421 | [:##h :!Sleft_arrow] 422 | [:##j :!Sdown_arrow] 423 | [:##k :!Sup_arrow] 424 | [:##l :!Sright_arrow] 425 | 426 | [:left_shift :shrink_selection] 427 | [:return_or_enter :insert_line_above] 428 | 429 | [:semicolon :expand_selection] 430 | [:quote :shrink_selection] 431 | 432 | [:##m :!Spage_down] 433 | [:##comma :!Spage_up] 434 | ; 435 | ]} 436 | 437 | 438 | {:des "movement" 439 | :rules [:movement-mode 440 | 441 | [:##y :!Cleft_arrow] 442 | [:##o :!Cright_arrow] 443 | 444 | [:##h :left_arrow] 445 | [:##j :down_arrow] 446 | [:##k :up_arrow] 447 | [:##l :right_arrow] 448 | 449 | [:semicolon :autocomplete] 450 | 451 | [:return_or_enter :insert_line_below] 452 | [:left_shift :expand_selection] 453 | ; 454 | ]} 455 | 456 | {:des "cursor" 457 | :rules [:cursor-mode 458 | [:h :cursor_find_match] 459 | [:j :cursor_below] 460 | [:k :cursor_above] 461 | [:j :acejump] 462 | [:l :acejump_line] 463 | [:m :acejump_multi] 464 | [:left_shift :cursor_select_all] 465 | [:l :developer_tools] 466 | ; 467 | ]} 468 | 469 | 470 | 471 | {:des "delete" 472 | :rules [:delete-mode 473 | [:escape :delete_line :code] 474 | [:escape :!Cdelete_or_backspace] 475 | [:hyphen :delete_line :code] 476 | [:caps_lock :delete_line :code] 477 | [:hyphen :!Cdelete_or_backspace] 478 | [:a :!Odelete_or_backspace nil {:held :delete_line}] 479 | [:s :delete_or_backspace] 480 | [:d :delete_forward] 481 | [:f :!Odelete_forward] 482 | [:g :!Cdelete_forward] 483 | ; 484 | ]} 485 | 486 | {:des "editor" 487 | :rules [:editor-mode 488 | [:hyphen :focus_next_editor_group] 489 | [:a :open_prev_editor] 490 | [:r :go_back] 491 | [:s :go_forward] 492 | [:t :open_next_editor] 493 | [:d :focus_prev_editor_group] 494 | ; 495 | ]} 496 | 497 | 498 | {:des "open" 499 | :rules [:open-mode 500 | ;; [:c [:code-project "~/.config"]] 501 | [:k ["~/.kit/kar update-karabiner-config"]] ;; 502 | [:w ["~/.kit/kar ~/.kit/cli/edit.js ~/.kenv/scripts/wiki-ten"]] 503 | ;; [:k ["~/.kit/kar update-karabiner-config"]] ;; 504 | ;; [:b [:code-project "~/.bin"]] 505 | ;; [:z [:code-project "~/.zfunc"]] 506 | ;; [:r [:code-project "~/.zshrc"]] 507 | 508 | ;; [:l [:code-project "~/projects/automatoes.com/_layouts"]] 509 | ;; [:e [:code-project "~/projects/egghead-io-nextjs"]] 510 | ;; [:r [:code-project "~/projects/egghead-rails"]] 511 | ;; [:t [:code-project "~/projects/thoughts"]] 512 | ;; [:s ["open simple://scripts/simple-switch"]] ; --disable-renderer-accessibility 513 | ;; [:h ["open simple://scripts/say-hi \"yo\""]] 514 | ;; [:p [:pad]] 515 | ; 516 | ]} 517 | 518 | {:des "password" 519 | :rules [[[:quote :2] [:type-secret "ONE_PASSWORD_LOGIN_EGGHEAD"]] 520 | [[:quote :1] [:type-secret "MAC_PASSWORD"]] 521 | [[:quote :3] [:type-secret "ONE_PASSWORD_LOGIN_PERSONAL"]] 522 | ; 523 | ]} 524 | 525 | 526 | {:des "snippets" 527 | :rules [:snippet-mode 528 | [:c [:c :o :n :s :o :l :e :period :l :o :g :open_paren :close_paren :left_arrow]] ;console.log() 529 | [:a [:a :w :a :i :t :spacebar]] ;await 530 | [:s [:a :s :y :n :c :spacebar]] ;async 531 | [:n [:spacebar :c :l :a :s :s :!Sn :a :m :e :equal_sign :!Squote :!Squote :left_arrow]] ;className="" 532 | ;; [:l [:open_bracket :a :l :t :close_bracket :open_paren :close_paren :left_arrow :left_arrow]] ;[]() 533 | [:e [:type-secret "BUSINESS_EMAIL"]] ; 534 | [:g [:type-secret "PERSONAL_EMAIL"]] 535 | [:x [:type-secret "SPAM_EMAIL"]] 536 | [:j [:type-secret "USERNAME"]] 537 | ; 538 | ]} 539 | 540 | ;bottom row 541 | 542 | {:des "emoji" 543 | :rules [:emoji-mode 544 | [:a [:paste ""]] ; 545 | [:b [:paste "😊"]] ;blush 546 | [:c [:paste "🤡"]] ;Clown 547 | [:d [:paste "💀"]] ;death 548 | [:e :emoji_picker] 549 | [:f [:paste "🔥"]] ;fire 550 | [:g [:paste "😬"]] ;grimace 551 | [:h [:paste "😍"]] ;heart-eyes 552 | [:i [:paste "👀"]] ;I 553 | [:j [:paste "😂"]] ;joking 554 | [:k [:paste "🤔"]] ;thinking 555 | [:l [:paste "❤️"]] ;love 556 | [:m [:paste "🤯"]] ;mind blown zmzmzmü§Øü§Ø 557 | [:n :emoji_picker] ; 558 | [:o [:paste "💩"]] ;pOop 559 | [:p [:paste "🎉"]] ;party 560 | [:q [:paste "🤫"]] ;quiet 561 | [:s [:paste "😅"]] ;sweat 562 | [:r [:paste "🏎"]] ;racecar 563 | [:s [:paste "😢"]] ;sad 564 | [:t [:paste "😭"]] ;thinking 565 | [:u [:paste "🤷‍♂️"]] ;shrUg 566 | [:v [:paste "😎"]] ;very cool 567 | [:w [:paste "😉"]] ;wink: 568 | [:x [:paste "😵"]] ;x-eyes 569 | [:y [:paste "😅"]] ;sweatY 570 | [:left_command [:paste "👍"]] 571 | [:left_option [:paste "👎"]] 572 | ; 573 | ]} 574 | 575 | {:des "command mode" 576 | :rules [:command-mode 577 | ;; [:n [:new-note]] ;h 578 | ;; [:t ["~/.simple/bin/new-thought"]] ;a script that creates a new journal mdx file and open in code 579 | ;; [:b [:new-blog]] ;a script that creates a new blog md file and open in code 580 | [:n :go_end] 581 | [:e :go_home]]} 582 | 583 | 584 | {:des "modify" 585 | :rules [:modify 586 | 587 | ; 588 | ]} 589 | 590 | 591 | ;apps 592 | {:des "chrome" 593 | :rules [:chrome 594 | [:left_command :left_command nil {:alone [:!Ct]}] 595 | ;; [:left_option :left_option nil {:alone ["open simple://scripts/list-chrome-tabs"]}] 596 | ;; [:right_option :focus_omnibar] 597 | ;; [:left_control :left_option nil {:alone [:!CSt]}] 598 | ;; [{:key :right_option :modi :left_command} :!COi] 599 | ;; [:d :open_dev_tools] 600 | 601 | [:condi :chrome ["multitouch_extension_finger_count_total" 1]] 602 | 603 | [:condi :chrome ["multitouch_extension_finger_count_total" 2]] 604 | [:d :open_dev_tools] 605 | [:a :!COleft_arrow] 606 | [:t :!COright_arrow] 607 | 608 | [:condi :chrome :escape-mode] 609 | [:f :chrome_full_screen] 610 | ;; [:grave_accent_and_tilde :a nil {:delayed {:invoked [:y] :canceled [:x]}}] 611 | ; 612 | ; 613 | ]} 614 | {:des "code-mode" :rules [:code-mode [:r :rename]]} 615 | 616 | 617 | {:des "code" 618 | :rules [:code 619 | [:left_command :left_command nil {:alone :go_to_file}] 620 | ;; [:left_option :left_option nil {:alone :focus_terminal}] 621 | ;; [:right_option :right_option nil {:alone :command_palette}] 622 | [:left_control :left_control nil {:alone :command_palette}] 623 | [:right_control :right_control nil {:alone :command_palette}] 624 | [:!Cr :replace]; 625 | 626 | 627 | [:home :start_debugger] 628 | [:end :restart_debugger] 629 | 630 | [:condi :code :modify-mode] 631 | ;view 632 | ;note - I try to keep these on my left hand so I can keep my right on the mouse 633 | [:condi :code :escape-mode] 634 | [:g :focus_git] ;; SCM 635 | [:e :focus_explorer] ;; Explorer 636 | [:x :focus_explorer] ;; Explorer 637 | [:s :!!s] ;; Status Bar 638 | ;; [:t :focus_terminal] 639 | ;; [:n :new_terminal] 640 | [:f :find_in_project] 641 | [:z [:!Ck :z]] ;zen modezz 642 | [:v :!!v] 643 | [:x :!!x] 644 | [:p :!!r] ;toggle panel 645 | [:semicolon :!!semicolon] 646 | 647 | 648 | ;; [:left_shift :!Cb] 649 | ; [:a :toggle_sidebar] 650 | 651 | ;trackpad 652 | [:condi :code ["multitouch_extension_finger_count_total" 1]] 653 | [:left_command :left_command nil {:alone :start_debugger}] 654 | ;; [:left_option :left_option nil {:alone :restart_debugger}] 655 | 656 | ;trackpad 2 657 | [:condi :code ["multitouch_extension_finger_count_total" 2]] 658 | [:t [:button1 :f2]] 659 | 660 | 661 | ; 662 | ]} 663 | 664 | 665 | {:des "final cut pro" 666 | :rules [:fcp 667 | [{:pkey :button3} 668 | [:h {:pkey :button1}] 669 | 670 | {:afterup {:key :a}}] 671 | [:condi :fcp :multitouch_extension_finger_count_total] 672 | [:delete_or_backspace [:button1 :delete_or_backspace]]]} 673 | 674 | 675 | 676 | 677 | 678 | {:des "slack" 679 | :rules [:slack 680 | [:left_command :left_command nil {:alone :!Ct}] 681 | ; 682 | ]} 683 | 684 | 685 | 686 | {:des "caps_lock" 687 | :rules [:caps_lock-mode 688 | [:##caps_lock :left_control] 689 | [:a :caps_lock] 690 | [:spacebar [:spacebar :equal_sign :spacebar]] 691 | [:g :focus_git] 692 | ; I don't use a caps_lock key on my keyboard 693 | ; 694 | ]} 695 | 696 | {:des "launch" 697 | :rules 698 | [:l-mode 699 | 700 | [:1 :open_1password] 701 | ;; [:a [:launch "Activity Monitor"]] 702 | ;; [:o [:launch "Loopback"]] 703 | ;; [:t ["~/.kit/kar ~/.kit/main/app-launcher.js"]] 704 | ;; [:e [:launch "Karabiner-EventViewer"]] 705 | [:c [:alfred "code" "com.vivaxy.workflow.open-in-vscode" " "]] 706 | [:d [:launch "Discord"]] 707 | [:f [:launch "Finder"]]; 708 | [:g [:launch "Google Chrome"]] 709 | ;; [:u [:launch "Music"]] 710 | [:t [:launch "iTerm"]] 711 | [:k "launchctl kickstart -k org.pqrs.karabiner.karabiner_console_user_server"] ;restart karabiner 712 | [:y [:launch "YouTube Music"]] 713 | [:r [:launch "Restream Chat"]] 714 | [:s [:launch "Slack"]] 715 | [:c [:launch "Google Chrome"]] ; 716 | [:v [:launch "VLC"]]; 717 | [:z [:launch "Visual Studio Code"]];viZ 718 | [:x [:launch "Messages"]]; 719 | ; 720 | ]} 721 | 722 | {:des "escape-mode" :rules 723 | [:escape-mode 724 | ; 725 | [:t ["~/.kit/kar todo-pad"]] 726 | [:a ["~/.kit/kar ~/.kit/main/app-launcher.js"]] 727 | [:c ["~/.kit/kar auto-center-app"]] 728 | [:n ["~/.kit/kar journal"]] 729 | [:w ["~/.kit/kar ~/.kit/cli/edit.js ~/.kenv/scripts/wiki-ten.js"]] 730 | [:b ["~/.kit/kar bugs"]] 731 | [:i ["~/.kit/kar script-ideas"]] 732 | [:r ["~/.kit/kar rhyme-finder"]] 733 | [:1 :!CO1] 734 | [:2 :!CO2] 735 | [:3 :!CO3] 736 | [:4 :!CO4] 737 | [:5 :!CO5] 738 | [:6 :!CO6] 739 | [:7 :!CO7] 740 | [:0 :!CO0] 741 | ; 742 | ]} 743 | 744 | 745 | 746 | 747 | 748 | 749 | 750 | 751 | {:des "spacebar" 752 | :rules [:spacebar-mode 753 | ;symbols [](){}<> 754 | [:a :open_bracket] 755 | [:s :close_bracket] 756 | 757 | [:d :open_paren] 758 | [:f :close_paren] 759 | 760 | [:tab [:open_bracket :open_bracket]] 761 | 762 | [:j :open_brace] 763 | [:k :close_brace] 764 | 765 | [:l :less_than] 766 | [:semicolon :greater_than] 767 | 768 | ;symbol sequences 769 | [:hyphen [:!S4 :!Sopen_bracket :!Sclose_bracket :left_arrow]]; ${} 770 | [:left_shift [:spacebar :equal_sign :spacebar]]; = 771 | [:q [:!S9 :!S0 :equal_sign :greater_than :spacebar]];()=> 772 | [:e [:!S9 :!S9 :!S0 :equal_sign :greater_than :spacebar :open_brace :close_brace :!S0 :left_arrow :left_arrow]];(()=> {}) 773 | 774 | [:g [:spacebar :equal_sign :greater_than :spacebar]]; => 775 | [:h [:equal_sign :open_brace :close_brace :left_arrow]];={} 776 | [:b [:equal_sign :open_brace :close_brace :left_arrow]];={} 777 | [:quote [:equal_sign :!Squote :!Squote :left_arrow]];="" 778 | 779 | ;macros 780 | 781 | 782 | ; 783 | ]} 784 | 785 | 786 | {:des "special characters" 787 | :rules [:semicolon-mode 788 | ;special characters: !@#$%^&*() 789 | ;; [:##a :!S1] 790 | ;; [:##s :!S2] 791 | ;; [:##d :!S3] 792 | ;; [:##f :!S4]; 793 | ;; [:##g :!S5] 794 | ;; [:##h :!S6] 795 | ;; [:##j :!S7] 796 | ;; [:##k :!S8] 797 | ;; [:##l :!S9] 798 | ;; [:##semicolon :!S0] 799 | [:e :!S1]; ! exclaim 800 | [:a :!S2]; @ at 801 | [:h :!S3]; # hash 802 | [:d :!S4]; $ dollar 803 | [:p :!S5]; % percent 804 | [:c :!S6]; ^ caret 805 | [:s :!S7]; & amperSand 806 | [:b :!S8]; * bullet 807 | ; 808 | ]} 809 | 810 | {:des "special characters again" 811 | :rules [:period-mode 812 | ;special characters: !@#$%^&*() 813 | ;; [:##a :!S1] 814 | ;; [:##s :!S2] 815 | ;; [:##d :!S3] 816 | ;; [:##f :!S4]; 817 | ;; [:##g :!S5] 818 | ;; [:##h :!S6] 819 | ;; [:##j :!S7] 820 | ;; [:##k :!S8] 821 | ;; [:##l :!S9] 822 | ;; [:##semicolon :!S0] 823 | [:e :!S1]; ! exclaim.e.e.!!!@!@.a@@/e/e/k/k/k/k/k/k/k 824 | [:a :!S2]; @ at 825 | [:h :!S3]; # hash 826 | [:d :!S4]; $ dollar 827 | [:p :!S5]; % percent 828 | [:c :!S6]; ^ caret 829 | [:s :!S7]; & amperSand 830 | [:b :!S8]; * bullet 831 | [:k [:code-project "~/.dotfiles/karabiner/karabiner.edn ~/.dotfiles/karabiner/"]] 832 | ; 833 | ]} 834 | 835 | {:des "slash-mode" 836 | :rules [:slash-mode 837 | ;open urls 838 | [:e [:open-chrome "egghead.io"]] 839 | [:g [:open-chrome "mail.google.com"]] 840 | [:j [:open-chrome "js.new"]]; 841 | [:k [:open-chrome "github.com/search?q=extension%3A.edn+filename%3Akarabiner.edn&type=Code&ref=advsearch&l=&l="]] 842 | [:l [:open-chrome "localhost:3000"]] 843 | [:m [:open-chrome "access.mymind.com/cards"]] 844 | [:n [:open-chrome "news.google.com"]] 845 | [:r [:open-chrome "roamresearch.com/#/app/egghead"]] 846 | [:s [:open-chrome "github.com/johnlindquist/simplescripts"]] 847 | [:t [:open-chrome "twitter.com"]] 848 | [:u [:open-chrome "egghead.io/lessons/new"]];Upload 849 | [:x [:open-chrome "next.egghead.io"]] 850 | [:y [:open-chrome "youtube.com"]] 851 | ; 852 | ]} 853 | 854 | {:des "numbers" 855 | :rules [:tab-mode 856 | [:##a :1] 857 | [:##s :2] 858 | [:##d :3] 859 | [:##f :4]; 860 | [:##g :5] 861 | [:##h :6] 862 | [:##j :7] 863 | [:##k :8] 864 | [:##l :9] 865 | [:##semicolon :0] 866 | [:##4 :capture_screenshot] 867 | ; 868 | ]} 869 | 870 | {:des "remap caps to ctrl" 871 | :rules [[:caps_lock :left_control]]} 872 | 873 | 874 | 875 | 876 | 877 | 878 | ; 879 | ]} 880 | 881 | 882 | 883 | 884 | ;; rule [:period ["media-mode" 1] nil {:afterup ["media-mode" 0] :alone :period}] 885 | ;; |_____| |_______________| |_| |_________________________________________| 886 | ;; 887 | 888 | ;; ! | means mandatory 889 | ;; # | means optional 890 | ;; C | left_command 891 | ;; T | left_control 892 | ;; O | left_option 893 | ;; S | left_shift 894 | ;; F | fn 895 | ;; Q | right_command 896 | ;; W | left_control 897 | ;; E | right_option 898 | ;; R | right_shift 899 | ;; 900 | ;; !! | mandatory command + control + optional + shift (hyper) 901 | ;; ## | optional any 902 | ;; --------------------------------------------------------------------------------