diff --git a/crates/nu-cli/src/reedline_config.rs b/crates/nu-cli/src/reedline_config.rs index 1b09e59166..55179ab0ae 100644 --- a/crates/nu-cli/src/reedline_config.rs +++ b/crates/nu-cli/src/reedline_config.rs @@ -711,6 +711,7 @@ pub(crate) fn create_keybindings(config: &Config) -> Result Result, mode: &Value, keybinding: &ParsedKeybinding, config: &Config, @@ -752,6 +755,7 @@ fn add_keybinding( Value::List { vals, .. } => { for inner_mode in vals { add_keybinding( + name, inner_mode, keybinding, config, diff --git a/crates/nu-protocol/src/config/reedline.rs b/crates/nu-protocol/src/config/reedline.rs index 330998c202..1694619e99 100644 --- a/crates/nu-protocol/src/config/reedline.rs +++ b/crates/nu-protocol/src/config/reedline.rs @@ -5,6 +5,7 @@ use crate::{engine::Closure, FromValue}; /// Definition of a parsed keybinding from the config object #[derive(Clone, Debug, FromValue, IntoValue, Serialize, Deserialize)] pub struct ParsedKeybinding { + pub name: Option, pub modifier: Value, pub keycode: Value, pub event: Value,