1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 19:47:45 +00:00

basenc: Move strings to markdown file (#4417)

basenc: moved help strings to markdown file
This commit is contained in:
zleyyij 2023-02-22 13:02:39 -07:00 committed by GitHub
parent b70131f148
commit a24da1d575
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 9 deletions

12
src/uu/basenc/basenc.md Normal file
View 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.

View file

@ -19,14 +19,10 @@ use uucore::{
use std::io::{stdin, Read};
use uucore::error::UClapError;
static ABOUT: &str = "\
Encode/decode data and print to standard output
With no FILE, or when FILE is -, read standard input.
use uucore::{help_about, help_usage};
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.
";
const ABOUT: &str = help_about!("basenc.md");
const USAGE: &str = help_usage!("basenc.md");
const ENCODINGS: &[(&str, Format)] = &[
("base64", Format::Base64),
@ -39,8 +35,6 @@ const ENCODINGS: &[(&str, Format)] = &[
("z85", Format::Z85),
];
const USAGE: &str = "{} [OPTION]... [FILE]";
pub fn uu_app() -> Command {
let mut command = base_common::base_app(ABOUT, USAGE);
for encoding in ENCODINGS {