mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-29 12:07:46 +00:00
Merge pull request #4703 from piotrkwiecinski/true-move-string-to-md-file
true: move help strings to markdown file
This commit is contained in:
commit
7ad367675e
2 changed files with 13 additions and 7 deletions
|
@ -7,14 +7,9 @@
|
||||||
use clap::{Arg, ArgAction, Command};
|
use clap::{Arg, ArgAction, Command};
|
||||||
use std::{ffi::OsString, io::Write};
|
use std::{ffi::OsString, io::Write};
|
||||||
use uucore::error::{set_exit_code, UResult};
|
use uucore::error::{set_exit_code, UResult};
|
||||||
|
use uucore::help_about;
|
||||||
|
|
||||||
static ABOUT: &str = "\
|
const ABOUT: &str = help_about!("true.md");
|
||||||
Returns true, a successful exit status.
|
|
||||||
|
|
||||||
Immediately returns with the exit status `0`, except when invoked with one of the recognized
|
|
||||||
options. In those cases it will try to write the help or version text. Any IO error during this
|
|
||||||
operation causes the program to return `1` instead.
|
|
||||||
";
|
|
||||||
|
|
||||||
#[uucore::main]
|
#[uucore::main]
|
||||||
pub fn uumain(args: impl uucore::Args) -> UResult<()> {
|
pub fn uumain(args: impl uucore::Args) -> UResult<()> {
|
||||||
|
|
11
src/uu/true/true.md
Normal file
11
src/uu/true/true.md
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
# true
|
||||||
|
|
||||||
|
```
|
||||||
|
true
|
||||||
|
```
|
||||||
|
|
||||||
|
Returns true, a successful exit status.
|
||||||
|
|
||||||
|
Immediately returns with the exit status `0`, except when invoked with one of the recognized
|
||||||
|
options. In those cases it will try to write the help or version text. Any IO error during this
|
||||||
|
operation causes the program to return `1` instead.
|
Loading…
Add table
Add a link
Reference in a new issue