From b70131f14891137d82dde824cf2832db189679ea Mon Sep 17 00:00:00 2001 From: zleyyij <75810274+zleyyij@users.noreply.github.com> Date: Wed, 22 Feb 2023 08:50:27 -0700 Subject: [PATCH] arch: move help strings to a markdown file (#4373) Co-authored-by: zleyyij --- src/uu/arch/arch.md | 14 ++++++++++++++ src/uu/arch/src/arch.rs | 5 +++-- 2 files changed, 17 insertions(+), 2 deletions(-) create mode 100644 src/uu/arch/arch.md diff --git a/src/uu/arch/arch.md b/src/uu/arch/arch.md new file mode 100644 index 000000000..7225ede2d --- /dev/null +++ b/src/uu/arch/arch.md @@ -0,0 +1,14 @@ +# arch + +``` +arch +``` + + +Display machine architecture + + +## After Help + +Determine architecture name for current machine. + diff --git a/src/uu/arch/src/arch.rs b/src/uu/arch/src/arch.rs index 62a07159e..a2208d8b0 100644 --- a/src/uu/arch/src/arch.rs +++ b/src/uu/arch/src/arch.rs @@ -10,9 +10,10 @@ use platform_info::*; use clap::{crate_version, Command}; use uucore::error::{FromIo, UResult}; +use uucore::{help_about, help_section}; -static ABOUT: &str = "Display machine architecture"; -static SUMMARY: &str = "Determine architecture name for current machine."; +static ABOUT: &str = help_about!("arch.md"); +static SUMMARY: &str = help_section!("after help", "arch.md"); #[uucore::main] pub fn uumain(args: impl uucore::Args) -> UResult<()> {