Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

more: move help strings to markdown file #4589

Merged
merged 3 commits into from
Mar 24, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/uu/more/more.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# more

```
more [OPTIONS] <FILE>...
```

A file perusal filter for CRT viewing.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CRT means Cathode Ray Tube
let's remove this old stuff
maybe:

Suggested change
A file perusal filter for CRT viewing.
Display the contents of a text file

6 changes: 5 additions & 1 deletion src/uu/more/src/more.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@ use unicode_segmentation::UnicodeSegmentation;
use unicode_width::UnicodeWidthStr;
use uucore::display::Quotable;
use uucore::error::{UResult, USimpleError, UUsageError};
use uucore::{format_usage, help_about, help_usage};

const ABOUT: &str = help_about!("more.md");
const USAGE: &str = help_usage!("more.md");
const BELL: &str = "\x07";

pub mod options {
Expand Down Expand Up @@ -97,7 +100,8 @@ pub fn uumain(args: impl uucore::Args) -> UResult<()> {

pub fn uu_app() -> Command {
Command::new(uucore::util_name())
.about("A file perusal filter for CRT viewing.")
.about(ABOUT)
.override_usage(format_usage(USAGE))
.version(crate_version!())
.infer_long_args(true)
.arg(
Expand Down