mirror of
https://github.com/ClementTsang/bottom.git
synced 2025-07-23 13:45:12 +02:00
change: Adds advanced kill option to default config text (#462)
Adds advanced_kill to the default config gen.
This commit is contained in:
parent
df13859ef2
commit
fbfa708d1d
@ -430,7 +430,8 @@ pub const DEFAULT_BATTERY_LAYOUT: &str = r##"
|
|||||||
// Config and flags
|
// Config and flags
|
||||||
pub const DEFAULT_CONFIG_FILE_PATH: &str = "bottom/bottom.toml";
|
pub const DEFAULT_CONFIG_FILE_PATH: &str = "bottom/bottom.toml";
|
||||||
|
|
||||||
pub const OLD_CONFIG_TEXT: &str = r##"# This is a default config file for bottom. All of the settings are commented
|
// TODO: Eventually deprecate this.
|
||||||
|
pub const CONFIG_TEXT: &str = r##"# This is a default config file for bottom. All of the settings are commented
|
||||||
# out by default; if you wish to change them uncomment and modify as you see
|
# out by default; if you wish to change them uncomment and modify as you see
|
||||||
# fit.
|
# fit.
|
||||||
|
|
||||||
@ -495,6 +496,8 @@ pub const OLD_CONFIG_TEXT: &str = r##"# This is a default config file for bottom
|
|||||||
#network_use_bytes = false
|
#network_use_bytes = false
|
||||||
# Displays the network widget with a log scale.
|
# Displays the network widget with a log scale.
|
||||||
#network_use_log = false
|
#network_use_log = false
|
||||||
|
# Show a more advanced process kill screen
|
||||||
|
#advanced_kill = false
|
||||||
|
|
||||||
# These are all the components that support custom theming. Note that colour support
|
# These are all the components that support custom theming. Note that colour support
|
||||||
# will depend on terminal support.
|
# will depend on terminal support.
|
||||||
|
@ -228,7 +228,7 @@ pub fn create_or_get_config(config_path: &Option<PathBuf>) -> error::Result<Conf
|
|||||||
fs::create_dir_all(parent_path)?;
|
fs::create_dir_all(parent_path)?;
|
||||||
}
|
}
|
||||||
// fs::File::create(path)?.write_all(CONFIG_TOP_HEAD.as_bytes())?;
|
// fs::File::create(path)?.write_all(CONFIG_TOP_HEAD.as_bytes())?;
|
||||||
fs::File::create(path)?.write_all(OLD_CONFIG_TEXT.as_bytes())?;
|
fs::File::create(path)?.write_all(CONFIG_TEXT.as_bytes())?;
|
||||||
Ok(Config::default())
|
Ok(Config::default())
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user