diff options
author | Canop <cano.petrole@gmail.com> | 2021-02-24 19:49:41 +0100 |
---|---|---|
committer | Canop <cano.petrole@gmail.com> | 2021-02-24 19:49:41 +0100 |
commit | 7d512894808500946a6acb6d4939d4ba1473c14d (patch) | |
tree | 78ce8071e4c3f85a2b22c621c5a75c03cca8d81a /src/tree | |
parent | ab3602693a5361187427a5ebab3e4705956c01e6 (diff) |
limit the number of panels to 2
Can be changed in conf with `max_panels_count`.
Fix #345
Diffstat (limited to 'src/tree')
-rw-r--r-- | src/tree/tree_options.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/tree/tree_options.rs b/src/tree/tree_options.rs index 862b8f9..636b9c8 100644 --- a/src/tree/tree_options.rs +++ b/src/tree/tree_options.rs @@ -1,6 +1,7 @@ use { super::Sort, crate::{ + cli::clap_args, conf::Conf, display::{Cols, DEFAULT_COLS}, errors::ConfError, @@ -76,7 +77,7 @@ impl TreeOptions { /// change tree options according to configuration pub fn apply_config(&mut self, config: &Conf) -> Result<(), ConfError> { if let Some(default_flags) = &config.default_flags { - let clap_app = crate::clap::clap_app().setting(clap::AppSettings::NoBinaryName); + let clap_app = clap_args::clap_app().setting(clap::AppSettings::NoBinaryName); let flags_args = format!("-{}", default_flags); let conf_matches = clap_app.get_matches_from(vec![&flags_args]); self.apply_launch_args(&conf_matches); |