mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-29 12:07:46 +00:00
basenc: Move strings to markdown file (#4417)
basenc: moved help strings to markdown file
This commit is contained in:
parent
b70131f148
commit
a24da1d575
2 changed files with 15 additions and 9 deletions
12
src/uu/basenc/basenc.md
Normal file
12
src/uu/basenc/basenc.md
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
# basenc
|
||||||
|
|
||||||
|
```
|
||||||
|
basenc [OPTION]... [FILE]"
|
||||||
|
```
|
||||||
|
|
||||||
|
Encode/decode data and print to standard output
|
||||||
|
With no FILE, or when FILE is -, read standard input.
|
||||||
|
|
||||||
|
When decoding, the input may contain newlines in addition to the bytes of
|
||||||
|
the formal alphabet. Use --ignore-garbage to attempt to recover
|
||||||
|
from any other non-alphabet bytes in the encoded stream.
|
|
@ -19,14 +19,10 @@ use uucore::{
|
||||||
use std::io::{stdin, Read};
|
use std::io::{stdin, Read};
|
||||||
use uucore::error::UClapError;
|
use uucore::error::UClapError;
|
||||||
|
|
||||||
static ABOUT: &str = "\
|
use uucore::{help_about, help_usage};
|
||||||
Encode/decode data and print to standard output
|
|
||||||
With no FILE, or when FILE is -, read standard input.
|
|
||||||
|
|
||||||
When decoding, the input may contain newlines in addition to the bytes of
|
const ABOUT: &str = help_about!("basenc.md");
|
||||||
the formal alphabet. Use --ignore-garbage to attempt to recover
|
const USAGE: &str = help_usage!("basenc.md");
|
||||||
from any other non-alphabet bytes in the encoded stream.
|
|
||||||
";
|
|
||||||
|
|
||||||
const ENCODINGS: &[(&str, Format)] = &[
|
const ENCODINGS: &[(&str, Format)] = &[
|
||||||
("base64", Format::Base64),
|
("base64", Format::Base64),
|
||||||
|
@ -39,8 +35,6 @@ const ENCODINGS: &[(&str, Format)] = &[
|
||||||
("z85", Format::Z85),
|
("z85", Format::Z85),
|
||||||
];
|
];
|
||||||
|
|
||||||
const USAGE: &str = "{} [OPTION]... [FILE]";
|
|
||||||
|
|
||||||
pub fn uu_app() -> Command {
|
pub fn uu_app() -> Command {
|
||||||
let mut command = base_common::base_app(ABOUT, USAGE);
|
let mut command = base_common::base_app(ABOUT, USAGE);
|
||||||
for encoding in ENCODINGS {
|
for encoding in ENCODINGS {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue