forked from extern/nushell
use simpler reedline (#6016)
This commit is contained in:
@ -2,8 +2,6 @@ use crate::{ShellError, Span, Value};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::collections::HashMap;
|
||||
|
||||
const ANIMATE_PROMPT_DEFAULT: bool = true;
|
||||
|
||||
/// Definition of a parsed keybinding from the config object
|
||||
#[derive(Serialize, Deserialize, Clone, Debug)]
|
||||
pub struct ParsedKeybinding {
|
||||
@ -56,7 +54,6 @@ pub struct Config {
|
||||
pub color_config: HashMap<String, Value>,
|
||||
pub use_grid_icons: bool,
|
||||
pub footer_mode: FooterMode,
|
||||
pub animate_prompt: bool,
|
||||
pub float_precision: i64,
|
||||
pub filesize_format: String,
|
||||
pub use_ansi_coloring: bool,
|
||||
@ -89,7 +86,6 @@ impl Default for Config {
|
||||
color_config: HashMap::new(),
|
||||
use_grid_icons: false,
|
||||
footer_mode: FooterMode::RowCount(25),
|
||||
animate_prompt: ANIMATE_PROMPT_DEFAULT,
|
||||
float_precision: 4,
|
||||
filesize_format: "auto".into(),
|
||||
use_ansi_coloring: true,
|
||||
@ -195,13 +191,6 @@ impl Value {
|
||||
eprintln!("$config.footer_mode is not a string")
|
||||
}
|
||||
}
|
||||
"animate_prompt" => {
|
||||
if let Ok(b) = value.as_bool() {
|
||||
config.animate_prompt = b;
|
||||
} else {
|
||||
eprintln!("$config.animate_prompt is not a bool")
|
||||
}
|
||||
}
|
||||
"float_precision" => {
|
||||
if let Ok(i) = value.as_integer() {
|
||||
config.float_precision = i;
|
||||
|
Reference in New Issue
Block a user