2.3 KiB
2.3 KiB
name, description
| name | description |
|---|---|
| key-chord-source-audit | Answer "what does chord X do" on Dank workstations: identify which layer (omp TUI, browser tool, niri, terminal) owns the chord before answering |
Key-chord source audit
Frank asks "what does mod+r / ctrl+X do?" — the chord lives in ONE layer of the stack; answering from the wrong layer is wrong. Check layers in order, in ONE pass.
Layers, in Frank's stack (most of his "mod" questions are niri)
- niri compositor (Mod = Super). Keybinds are NOT in
~/.config/niri/config.kdl— it onlyincludescfg/*.kdl. Grep~/.config/niri/cfg/keybinds.kdldirectly. Notation:Mod+R,Mod+CTRL+Alt+H. Preset-width cycle (Mod+R) usespreset-column-widthsfromcfg/rules.kdl; no rule → built-in proportions 3/4, 1/3, 1/2, 2/3, 9/10, 1. - omp TUI: defaults in
~/.bun/install/global/node_modules/@oh-my-pi/pi-coding-agent/dist/cli.js— grepdefaultKeys:\["…"(array form) anddefaultKeys:"…"(string form; needs a second pattern). Recognized modifiers: ctrl/shift/alt/super only; nometa/modalias. User remaps:~/.omp/agent/keybindings.yml(check existence first; absent = no remaps). Docs:omp://keybindings.md. - omp browser tool:
Mod+Keyis Playwright notation (Mod→ Ctrl on Linux, Cmd on macOS), used bytab.press(); e.g.Mod+R= page reload. Tern backendternKey()throws on literalMod; puppeteer path passes names through. - Terminals/tmux:
~/.config/ghostty/config.ghostty+ghostty/auto/,foot.ini,kitty.conf,~/.tmux.conf— keybind/bind/map lines.
Procedure
- Classify the notation the user used:
Mod+…→ niri/Playwright;Ctrl+…→ TUI/terminal; tmux prefix → tmux. - Grep that layer's config FIRST, expanding includes (config.kdl → cfg/*.kdl is the trap that caused a wrong answer).
- For omp bundle greps: two
defaultKeysforms exist;super+rpattern also matchessuper+right— anchor with word boundary. - Quote the exact config line as evidence; state the layer that owns the chord.
Verification
- niri keybinds:
grep -n "Mod+R" ~/.config/niri/cfg/keybinds.kdl(not config.kdl). - omp:
grep -o '"app[^"]*":{defaultKeys:[^}]*' cli.jsfor app actions;grep -rn "defaultKeys" pi-tui/src/keybindings.tsfor editor actions.