co-mono/packages
Aos Dabbagh 23a4fd1159 fix: load keybindings before --resume session picker
The problem: I wanted to be able to select my session (either from
`/resume` or `--resume`) with different keybindings.

The issue: when running `pi --resume`, custom keybindings from
`~/.pi/agent/keybindings.json` were not being applied to the session
picker. This happened because `KeybindingsManager.create()` was only
called when `InteractiveMode` initialized, but the session picker runs
before that in `main.ts`.

The session picker uses `getEditorKeybindings()` for navigation
(selectUp/selectDown etc.), which returns the global default keybindings
if `setEditorKeybindings()` hasn't been called yet.

Fix: Call `KeybindingsManager.create()` inside the `--resume` block
before showing the session picker. This loads user keybindings and sets
them globally.

The current fix results in double-init of keybindings when entering
interactive mode which _should_ be harmless, since it's the same same
config loaded twice, but is minimal and only affects the `--resume`
path.

I considered passing keybindings from `main()` to `InteractiveMode` -
it's cleaner but requires API changes.

Also documented the `select*` keybindings in README.md.
2026-01-11 19:22:52 +01:00
..
agent Add [Unreleased] section for next cycle 2026-01-11 04:11:34 +01:00
ai Add [Unreleased] section for next cycle 2026-01-11 04:11:34 +01:00
coding-agent fix: load keybindings before --resume session picker 2026-01-11 19:22:52 +01:00
mom Add [Unreleased] section for next cycle 2026-01-11 04:11:34 +01:00
pods Release v0.42.5 2026-01-11 04:10:49 +01:00
tui test(tui): cover style reset cases 2026-01-11 19:01:16 +01:00
web-ui Add [Unreleased] section for next cycle 2026-01-11 04:11:34 +01:00