partial completions (#4704)

This commit is contained in:
Fernando Herrera
2022-03-03 09:13:44 +00:00
committed by GitHub
parent d90b7953dd
commit 2fd42d25b1
4 changed files with 12 additions and 1 deletions

View File

@ -26,6 +26,7 @@ pub struct Config {
pub filesize_format: String,
pub use_ansi_coloring: bool,
pub quick_completions: bool,
pub partial_completions: bool,
pub edit_mode: String,
pub max_history_size: i64,
pub log_level: String,
@ -49,6 +50,7 @@ impl Default for Config {
filesize_format: "auto".into(),
use_ansi_coloring: true,
quick_completions: true,
partial_completions: true,
edit_mode: "emacs".into(),
max_history_size: 1000,
log_level: String::new(),
@ -160,6 +162,13 @@ impl Value {
eprintln!("$config.quick_completions is not a bool")
}
}
"partial_completions" => {
if let Ok(b) = value.as_bool() {
config.partial_completions = b;
} else {
eprintln!("$config.partial_completions is not a bool")
}
}
"rm_always_trash" => {
if let Ok(b) = value.as_bool() {
config.rm_always_trash = b;