From e339a4969f2db31a7d9ed08c5b9a1899345ef38e Mon Sep 17 00:00:00 2001 From: Noah Masur <7386960+nmasur@users.noreply.github.com> Date: Thu, 27 Aug 2026 11:30:47 -0600 Subject: [PATCH] add back keybindings for zellij --- docs/CHANGELOG.md | 2 +- .../modules/nmasur/presets/programs/zellij.nix | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 7083fc97..327e6a62 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -4,7 +4,7 @@ - Fixed macOS shortcuts (`Cmd+T`, `Ctrl+Tab`, `Cmd+Shift+]`, `Cmd+Shift+[`, `Cmd+K`, `Cmd+Shift+E`) in Zellij + Ghostty after disabling the Kitty keyboard protocol: - Mapped Ghostty keybindings (`super+t`, `super+shift+]`, `super+shift+[`, `ctrl+tab`, `ctrl+shift+tab`, `super+k`, `super+shift+e`) to send standard `Alt` (`ESC`-prefix) text sequences (`\x1bt`, `\x1b}`, `\x1b{`, `\x1bK`, `\x1bE`). - - Added matching unconditional `Alt` keybindings (`Alt t`, `Alt Shift ]`, `Alt Shift [`, `Alt Shift k`, `Alt Shift e`) in `zellij.nix` for tab creation, tab navigation, scroll mode, and scrollback editing. + - Added matching `Alt` keybindings (`Alt t`, `Alt ]`, `Alt }`, `Alt [`, `Alt {`, `Alt Shift k`, `Alt Shift e`) in `zellij.nix` for tab creation, tab navigation, scroll mode, and scrollback editing. Symbols like `]` and `}` are parsed by Zellij's termwiz input engine as distinct character codes (`'}'` vs `']'`), so binding both `Alt }` and `Alt Shift ]` ensures `\x1b}` triggers tab navigation correctly. - Keeps Kitty keyboard protocol disabled in Zellij (`support_kitty_keyboard_protocol = false`) so no CSI-u flags leak into Fish shell, guaranteeing zero post-TUI typing lag while restoring all shortcuts. - Fixed persistent Fish typing lag after long TUI sessions (Neovim, jjui, Yazi) inside Zellij + Ghostty, which the `no-query-term` / Ghostty-integration fixes from 2026-08-25 did not resolve: diff --git a/platforms/home-manager/modules/nmasur/presets/programs/zellij.nix b/platforms/home-manager/modules/nmasur/presets/programs/zellij.nix index 3f6969e0..724cd86a 100644 --- a/platforms/home-manager/modules/nmasur/presets/programs/zellij.nix +++ b/platforms/home-manager/modules/nmasur/presets/programs/zellij.nix @@ -295,15 +295,33 @@ in "bind \"Super Shift ]\"" = { GoToNextTab = { }; }; + "bind \"Alt ]\"" = { + GoToNextTab = { }; + }; + "bind \"Alt }\"" = { + GoToNextTab = { }; + }; "bind \"Alt Shift ]\"" = { GoToNextTab = { }; }; + "bind \"Alt Shift }\"" = { + GoToNextTab = { }; + }; "bind \"Super Shift [\"" = { GoToPreviousTab = { }; }; + "bind \"Alt [\"" = { + GoToPreviousTab = { }; + }; + "bind \"Alt {\"" = { + GoToPreviousTab = { }; + }; "bind \"Alt Shift [\"" = { GoToPreviousTab = { }; }; + "bind \"Alt Shift {\"" = { + GoToPreviousTab = { }; + }; "bind \"Ctrl Tab\"" = { GoToNextTab = { }; };