Skip to content

Commit

Permalink
Merge pull request #4770 from m11o/readlink-move-strings-to-md-file
Browse files Browse the repository at this point in the history
readlink: move help strings to markdown file
  • Loading branch information
tertsdiepraam authored Apr 22, 2023
2 parents 32d313c + 31c1d9c commit 698bdf5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
7 changes: 7 additions & 0 deletions src/uu/readlink/readlink.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# readlink

```
readlink [OPTION]... [FILE]...
```

Print value of a symbolic link or canonical file name.
8 changes: 4 additions & 4 deletions src/uu/readlink/src/readlink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ use std::path::{Path, PathBuf};
use uucore::display::Quotable;
use uucore::error::{FromIo, UResult, USimpleError, UUsageError};
use uucore::fs::{canonicalize, MissingHandling, ResolveMode};
use uucore::{format_usage, show_error};
use uucore::{format_usage, help_about, help_usage, show_error};

const ABOUT: &str = "Print value of a symbolic link or canonical file name.";
const USAGE: &str = "{} [OPTION]... [FILE]...";
const ABOUT: &str = help_about!("readlink.md");
const USAGE: &str = help_usage!("readlink.md");
const OPT_CANONICALIZE: &str = "canonicalize";
const OPT_CANONICALIZE_MISSING: &str = "canonicalize-missing";
const OPT_CANONICALIZE_EXISTING: &str = "canonicalize-existing";
Expand Down Expand Up @@ -99,7 +99,7 @@ pub fn uu_app() -> Command {
Command::new(uucore::util_name())
.version(crate_version!())
.about(ABOUT)
.override_help(format_usage(USAGE))
.override_usage(format_usage(USAGE))
.infer_long_args(true)
.arg(
Arg::new(OPT_CANONICALIZE)
Expand Down

0 comments on commit 698bdf5

Please sign in to comment.