diff --git a/src/uu/cat/cat.md b/src/uu/cat/cat.md new file mode 100644 index 000000000..0188be123 --- /dev/null +++ b/src/uu/cat/cat.md @@ -0,0 +1,11 @@ +# cat + +## Usage +``` +cat [OPTION]... [FILE]... +``` + +## About + +Concatenate FILE(s), or standard input, to standard output +With no FILE, or when FILE is -, read standard input. diff --git a/src/uu/cat/src/cat.rs b/src/uu/cat/src/cat.rs index 35ef5abc1..d8cc46035 100644 --- a/src/uu/cat/src/cat.rs +++ b/src/uu/cat/src/cat.rs @@ -33,11 +33,10 @@ use std::net::Shutdown; use std::os::unix::fs::FileTypeExt; #[cfg(unix)] use std::os::unix::net::UnixStream; -use uucore::format_usage; +use uucore::{format_usage, help_section, help_usage}; -static USAGE: &str = "{} [OPTION]... [FILE]..."; -static ABOUT: &str = "Concatenate FILE(s), or standard input, to standard output -With no FILE, or when FILE is -, read standard input."; +const USAGE: &str = help_usage!("cat.md"); +const ABOUT: &str = help_section!("about", "cat.md"); #[derive(Error, Debug)] enum CatError {