From c8cba4946328f44894a671a3029bd6e6904a2480 Mon Sep 17 00:00:00 2001 From: Clement Tsang <34804052+ClementTsang@users.noreply.github.com> Date: Thu, 14 Nov 2024 05:34:05 -0500 Subject: [PATCH] other: add missing process column comment/schema description (#1623) * add todo * rerun schema --- schema/nightly/bottom.json | 1 + src/options.rs | 1 + src/widgets/process_table/process_columns.rs | 1 + 3 files changed, 3 insertions(+) diff --git a/schema/nightly/bottom.json b/schema/nightly/bottom.json index efe6ce71..68e04f00 100644 --- a/schema/nightly/bottom.json +++ b/schema/nightly/bottom.json @@ -674,6 +674,7 @@ } }, "ProcColumn": { + "description": "A column in the process widget.", "type": "string", "enum": [ "CPU%", diff --git a/src/options.rs b/src/options.rs index ed857acc..a0d3119b 100644 --- a/src/options.rs +++ b/src/options.rs @@ -261,6 +261,7 @@ pub(crate) fn init_app( if cfg.columns.is_empty() { None } else { + // TODO: Should we be using an indexmap? Or maybe allow dupes. Some(IndexSet::from_iter( cfg.columns.iter().map(ProcWidgetColumn::from), )) diff --git a/src/widgets/process_table/process_columns.rs b/src/widgets/process_table/process_columns.rs index 55524b6e..d920ad1a 100644 --- a/src/widgets/process_table/process_columns.rs +++ b/src/widgets/process_table/process_columns.rs @@ -8,6 +8,7 @@ use crate::{ utils::general::sort_partial_fn, }; +/// A column in the process widget. #[derive(Debug, PartialEq, Eq, Copy, Clone, Hash)] #[cfg_attr( feature = "generate_schema",