mirror of
https://github.com/nushell/nushell.git
synced 2025-06-30 22:50:14 +02:00
@ -161,6 +161,8 @@ pub fn evaluate_repl(
|
||||
}
|
||||
};
|
||||
|
||||
line_editor = line_editor.with_buffer_editor(config.buffer_editor.clone(), "nu".into());
|
||||
|
||||
if config.sync_history_on_enter {
|
||||
if is_perf_true {
|
||||
info!("sync history {}:{}:{}", file!(), line!(), column!());
|
||||
|
@ -47,6 +47,7 @@ pub struct Config {
|
||||
pub menus: Vec<ParsedMenu>,
|
||||
pub rm_always_trash: bool,
|
||||
pub shell_integration: bool,
|
||||
pub buffer_editor: String,
|
||||
pub disable_table_indexes: bool,
|
||||
}
|
||||
|
||||
@ -74,6 +75,7 @@ impl Default for Config {
|
||||
menus: Vec::new(),
|
||||
rm_always_trash: false,
|
||||
shell_integration: false,
|
||||
buffer_editor: String::new(),
|
||||
disable_table_indexes: false,
|
||||
}
|
||||
}
|
||||
@ -256,6 +258,14 @@ impl Value {
|
||||
eprintln!("$config.shell_integration is not a bool")
|
||||
}
|
||||
}
|
||||
"buffer_editor" => {
|
||||
if let Ok(v) = value.as_string() {
|
||||
config.buffer_editor = v.to_lowercase();
|
||||
} else {
|
||||
eprintln!("$config.buffer_editor is not a string")
|
||||
}
|
||||
}
|
||||
|
||||
"disable_table_indexes" => {
|
||||
if let Ok(b) = value.as_bool() {
|
||||
config.disable_table_indexes = b;
|
||||
|
Reference in New Issue
Block a user