User guide / Custom key bindings

Upgrading to 0.5

Development reference · View source

keys.scopes has been removed and produces a diagnostic. Move each buffer-type table to its named mode under keys.bind: for example, scopes.markdown.normal becomes bind.markdown, scopes.terminal.insert becomes bind.terminal-insert, scopes.global.list becomes bind.list, and scopes.session-manager.list becomes bind.session-manager.

Existing keys.bind.normal syntax remains valid with new semantics: it changes text Normal and modes that explicitly inherit it, including Markdown. It no longer overlays every specialized buffer type. Move former 0.4 global Normal bindings to keys.bind.modal-keys. Use keys.bind.common only for actions valid in every inheriting mode, including Insert and Replace. Check Select inheritance when translating old separate Normal and Select tables. copy-key-binding emits the named table that supplies the inspected key. Use :keymap-export to write the effective bindings as a configuration fragment.