-
Notifications
You must be signed in to change notification settings - Fork 3
termnial_settings
zago's M+... shortcuts require the terminal emulator to send Alt (called
Option on macOS) as a Meta input. The most compatible representation is an
ESC prefix: Alt+V sends ESC followed by v (\x1bv). Avoid the old
high-bit Meta mode unless a specific application requires it.
Add this to the Ghostty configuration file:
macos-option-as-alt = trueThe usual macOS path is:
~/Library/Application Support/com.mitchellh.ghostty/config.ghostty
~/.config/ghostty/config.ghostty is also supported. Reload the configuration
or restart Ghostty after changing it.
Reference: Ghostty configuration and
macos-option-as-alt.
For cmux's TUI configuration, enable both macOS Option-as-Alt handling and Alt shortcuts:
keys.macos_option_as_alt = true
keys.alt_shortcuts = true
The same options can be represented in a JSON configuration as:
{
"keys": {
"macos_option_as_alt": true,
"alt_shortcuts": true
}
}If Option is composing macOS special characters instead of reaching zago,
check macos_option_as_alt first.
Reference: cmux TUI configuration.
- Open Settings / Preferences → Profiles → Keys.
- Set Left Option key to Esc+.
- Set Right Option key to Esc+ as well if both Option keys should act as Meta.
Esc+ sends ESC before the character. Do not select the legacy high-bit
Meta mode for normal zago use.
Reference: iTerm2 Profiles → Keys.
Windows Terminal normally sends Alt as a terminal modifier, so it usually needs no special Alt/Meta setting. If a shortcut does not reach zago:
- Open Settings → Actions.
- Search for the shortcut, such as
Alt+Left,Alt+Right, orAlt+Up. - Remove or change any Windows Terminal action that intercepts it.
- Open a new terminal tab and test again.
The important requirement is that Windows Terminal forwards the Alt sequence to the terminal application instead of using it for a tab or window command.
GNOME Terminal, Konsole, xterm, and most X11/Wayland terminal emulators already send Alt/Meta as an ESC prefix. If the terminal offers an option named Meta sends Escape, Alt sends Escape, or similar, enable it.
For xterm, the equivalent setting is metaSendsEscape:
xterm -xrm 'XTerm*metaSendsEscape: true'In Konsole, check Settings → Edit Current Profile → Keyboard and make sure custom key bindings do not intercept zago's Alt shortcuts.
References: xterm Meta Sends Escape and Konsole key bindings.
The Linux virtual console, such as Ctrl+Alt+F1, is the main Linux environment
where Meta may use the old high-bit form by default. Check the current mode:
setmetamodeSwitch the current virtual terminal to an ESC prefix:
setmetamode escprefixThe setting is per virtual terminal. Apply it to the terminals you use from a startup script if needed:
for tty in /dev/tty[1-6]; do
setmetamode escprefix < "$tty"
doneReference: setmetamode(1).
tmux, screen, and SSH generally forward the bytes received from the outer terminal; they do not normally repair Alt/Meta encoding. First verify the outermost terminal, then check tmux or screen bindings for intercepted Alt shortcuts.
Zellij defaults to using Ctrl + <key> for mode switching (e.g. Ctrl+S for Scroll mode, Ctrl+O for Session mode, Ctrl+P for Pane mode, Ctrl+N for Resize mode, Ctrl+Q to quit Zellij) and Alt + <key> for quick pane navigation (e.g. Alt+N/Alt+P for next/previous pane, Alt+F for floating panes). These conflict significantly with zago's standard Nano-compatible keybindings (such as Ctrl+S to save, Ctrl+O to write out, Ctrl+P/Ctrl+N for cursor movement, and Alt+N/Alt+P for search and AI proposal navigation).
To use zago smoothly inside Zellij, consider the following options:
-
Use Locked Mode (Recommended):
-
Manual Toggle: Press
Ctrl+Ginside Zellij to enter Locked Mode. In locked mode, allCtrlandAltshortcuts exceptCtrl+G(which unlocks) pass directly through to zago. -
Default to Locked Mode: In your Zellij config file (
~/.config/zellij/config.kdl), set:default_mode "locked"
-
Note: Inside zago, press
Escinstead ofCtrl+Gwhen canceling selections or prompt dialogs so you do not accidentally exit locked mode.
-
Manual Toggle: Press
-
Use the
tmuxKeybinding Preset:- Zellij provides a tmux keybinding mode where multiplexer actions require a prefix key (such as
Ctrl+B), freeing normalCtrlandAltkeys for your editor. - You can also unbind conflicting keys in
~/.config/zellij/config.kdl.
- Zellij provides a tmux keybinding mode where multiplexer actions require a prefix key (such as
-
Use Function Keys in zago:
- zago supports standard F1–F12 function keys (such as
F2for Save & Exit,F3for WriteOut,F6for WhereIs search,F7for Table Mode,F8for Canvas Mode,F9/F10for Cut/Uncut), which bypass terminal multiplexer Ctrl/Alt interceptions.
- zago supports standard F1–F12 function keys (such as
Run:
cat -vPress Alt+V. You should see something like:
^[v
^[ represents ESC. Press Ctrl+C to exit cat. You can then test zago's
M+V or M+W shortcuts directly.