Files
codex/docs/example-config.md
Felipe Coury cb3e5baa73 feat(tui): add configurable Vim keymap and startup default
Expose Vim bindings through the TUI keymap config and add a startup
toggle so Vim mode can be enabled by default.

Wire runtime keymap handling for Vim actions, add
`tui.vim_mode_default` to config parsing/runtime config, apply the
default in ChatWidget startup paths, and update docs/default
keymap/schema accordingly.
2026-04-23 10:35:17 -03:00

46 lines
966 B
Markdown

# Sample configuration
For a full sample configuration, see [this documentation](https://developers.openai.com/codex/config-sample).
## Keymap snippet
```toml
[tui]
vim_mode_default = false
[tui.keymap]
preset = "latest" # currently points to v1 defaults
[tui.keymap.global]
open_transcript = "ctrl-t"
open_external_editor = "ctrl-g"
[tui.keymap.chat]
edit_previous_message = "esc"
confirm_edit_previous_message = "enter"
[tui.keymap.composer]
submit = "enter"
queue = "tab"
toggle_shortcuts = ["?", "shift-?"]
[tui.keymap.pager]
close = ["q", "ctrl-c"]
close_transcript = ["ctrl-t"]
[tui.keymap.list]
accept = "enter"
cancel = "esc"
[tui.keymap.approval]
approve = "y"
decline = ["esc", "n"]
[tui.keymap.onboarding]
quit = ["q", "ctrl-c", "ctrl-d"]
```
For a complete, commented template:
Keymap template: https://github.com/openai/codex/blob/main/docs/default-keymap.toml
For precedence, safety invariants, and testing notes, see `docs/tui-keymap.md`.