From 07fd2152f41d1a65d9262691bbe896f8d84dabca Mon Sep 17 00:00:00 2001 From: Clement Tsang <34804052+ClementTsang@users.noreply.github.com> Date: Wed, 7 Dec 2022 04:28:43 -0500 Subject: [PATCH] docs: update changelog + docs for default expansion feature (#928) --- CHANGELOG.md | 1 + docs/content/configuration/command-line-flags.md | 1 + docs/content/configuration/config-file/flags.md | 1 + sample_configs/default_config.toml | 2 +- src/clap.rs | 4 ++-- 5 files changed, 6 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 929bf847..a3afd99e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -35,6 +35,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [#881](https://github.com/ClementTsang/bottom/pull/881): Add pasting to the search bar. - [#892](https://github.com/ClementTsang/bottom/pull/892): Add custom retention periods for data. - [#899](https://github.com/ClementTsang/bottom/pull/899): Add non-normalized CPU usage to processes. +- [#919](https://github.com/ClementTsang/bottom/pull/919): Add an option to expand the default widget on startup. ## [0.6.8] - 2022-02-01 diff --git a/docs/content/configuration/command-line-flags.md b/docs/content/configuration/command-line-flags.md index 36d18c0a..86fad044 100644 --- a/docs/content/configuration/command-line-flags.md +++ b/docs/content/configuration/command-line-flags.md @@ -46,3 +46,4 @@ The following flags can be provided to bottom in the command line to change the | `--enable_gpu_memory` | Enable collecting and displaying GPU memory usage. | | `--retention` | How much data is stored at once in terms of time. | | `-n`, `--unnormalized_cpu` | Show process CPU% without normalizing over the number of cores. | +| `-e`, `--expanded` | Expand the default widget upon starting the app. | diff --git a/docs/content/configuration/config-file/flags.md b/docs/content/configuration/config-file/flags.md index 606eef63..af84fcbd 100644 --- a/docs/content/configuration/config-file/flags.md +++ b/docs/content/configuration/config-file/flags.md @@ -39,3 +39,4 @@ Most of the [command line flags](../../command-line-flags) have config file equi | `enable_gpu_memory` | Boolean | Shows the GPU memory widget. | | `retention` | String (human readable time, such as "10m", "1h", etc.) | How much data is stored at once in terms of time. | | `unnormalized_cpu` | Boolean | Show process CPU% without normalizing over the number of cores. | +| `expanded_on_startup` | Boolean | Expand the default widget upon starting the app. | diff --git a/sample_configs/default_config.toml b/sample_configs/default_config.toml index 3df841e5..947c8710 100644 --- a/sample_configs/default_config.toml +++ b/sample_configs/default_config.toml @@ -43,7 +43,7 @@ # Override layout default widget #default_widget_type = "proc" #default_widget_count = 1 -# Expand selected widget upon starting the app +# Expand the default widget upon starting the app. #expanded_on_startup = true # Use basic mode #basic = false diff --git a/src/clap.rs b/src/clap.rs index 1d11096d..3903eb61 100644 --- a/src/clap.rs +++ b/src/clap.rs @@ -319,8 +319,8 @@ use CPU (3) as the default instead. let expanded_on_startup = Arg::new("expanded_on_startup") .long("expanded") .short('e') - .help("Expand selected widget upon starting the app.") - .long_help("Expand selected widget upon starting the app. Same as pressing \"e\" inside the app. Use with \"default_widget_type\" and \"default_widget_count\" to select desired expanded widget. This flag has no effect in basic mode (--basic)"); + .help("Expand the default widget upon starting the app.") + .long_help("Expand the default widget upon starting the app. Same as pressing \"e\" inside the app. Use with \"default_widget_type\" and \"default_widget_count\" to select desired expanded widget. This flag has no effect in basic mode (--basic)"); let rate = Arg::new("rate") .short('r')