mirror of
https://github.com/ClementTsang/bottom.git
synced 2024-08-16 15:10:50 +03:00
Add basic flag to sample config, also fixed incorrect flag name for configs.
This commit is contained in:
parent
808fe4deb1
commit
9cad3bb4ec
@ -34,6 +34,9 @@
|
||||
#default_widget = "network_default"
|
||||
#default_widget = "process_default"
|
||||
|
||||
# Basic mode
|
||||
#basic = true
|
||||
|
||||
|
||||
# These are all the components that support custom theming. Currently, it only
|
||||
# supports taking in a string representing a hex colour. Note that colour support
|
||||
|
@ -26,7 +26,7 @@ pub struct ConfigFlags {
|
||||
pub regex: Option<bool>,
|
||||
pub default_widget: Option<String>,
|
||||
pub show_disabled_data: Option<bool>,
|
||||
pub basic_mode: Option<bool>,
|
||||
pub basic: Option<bool>,
|
||||
//disabled_cpu_cores: Option<Vec<u64>>, // TODO: [FEATURE] Enable disabling cores in config/flags
|
||||
}
|
||||
|
||||
@ -176,8 +176,8 @@ pub fn get_use_basic_mode_option(matches: &clap::ArgMatches<'static>, config: &C
|
||||
if matches.is_present("BASIC_MODE") {
|
||||
return true;
|
||||
} else if let Some(flags) = &config.flags {
|
||||
if let Some(basic_mode) = flags.basic_mode {
|
||||
return basic_mode;
|
||||
if let Some(basic) = flags.basic {
|
||||
return basic;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user