User guide / Custom key bindings

Discovering actions and bindings

Development reference · View source

Space h is the Help prefix: Space h k runs :describe-key, and Space h a runs :browse-actions; Space h m runs :describe-mode. Space ? still opens contextual help. The companion :copy-key-binding command has no default key. Describe key captures a sequence in the current buffer type and mode without running it. Escape cancels. The result reports the accepted configuration source and line when available, action steps, and YAML that the current compiler accepts. Runtime plugin bindings use their plugin configuration instead. The copy command copies the most recently inspected copyable binding.

The action browser opens a searchable picker. Enter inspects an action; Tab filters to the current buffer type and mode. Details distinguish plain effective keys from membership in composed bindings, and show descriptor contracts and runtime capability gates. Document state and action-specific guards can still prevent an action from running.

:keymap-export [path] writes the effective bindings, descriptions, mode graph, configured macros, and UI/pointer overrides as a YAML configuration fragment. It has no default key. Without a path it writes keymap.yaml beside the per-user configuration file, like :write-config; relative paths use the working directory. Existing files are never replaced. Choose another path to export again.

Load the fragment on top of the same preset, platform and fast-pane-key setting. It contains root modes, buffer-types and keys sections: merge those sections into your configuration, or use the fragment as a configuration file. Remappings are resolved to explicit keys and exact removals. Export, load and export again produces identical YAML and executable bindings. Planned/unsupported bindings, representative targets and alias teaching metadata are omitted. Unchanged list and structural UI-owned bindings remain supplied by the preset; plugin registrations and bindings remain in plugins[].bindings. The export refuses a result above 65,536 assignments before writing a file. Generated descriptions use canonical action names and arguments, escape control characters, and are limited to 1024 UTF-8 bytes; explicit descriptions are preserved. The post-0.5 list executor will allow full export of list-owner rows.