1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-29 20:17:45 +00:00

groups: move move help strings to markdown file

This commit is contained in:
Piotr Kwiecinski 2023-03-19 15:46:42 +01:00
parent cc46de7f1f
commit 053a1216a3
2 changed files with 11 additions and 11 deletions

8
src/uu/groups/groups.md Normal file
View file

@ -0,0 +1,8 @@
# groups
```
groups [OPTION]... [USERNAME]...
```
Print group memberships for each `USERNAME` or, if no `USERNAME` is specified, for
the current process (which may differ if the groups database has changed).

View file

@ -17,23 +17,15 @@
use std::error::Error; use std::error::Error;
use std::fmt::Display; use std::fmt::Display;
use uucore::{ use uucore::{display::Quotable, entries::{get_groups_gnu, gid2grp, Locate, Passwd}, error::{UError, UResult}, format_usage, help_about, help_usage, show};
display::Quotable,
entries::{get_groups_gnu, gid2grp, Locate, Passwd},
error::{UError, UResult},
format_usage, show,
};
use clap::{crate_version, Arg, ArgAction, Command}; use clap::{crate_version, Arg, ArgAction, Command};
mod options { mod options {
pub const USERS: &str = "USERNAME"; pub const USERS: &str = "USERNAME";
} }
static ABOUT: &str = "Print group memberships for each USERNAME or, \ const ABOUT: &str = help_about!("groups.md");
if no USERNAME is specified, for\nthe current process \ const USAGE: &str = help_usage!("groups.md");
(which may differ if the groups database has changed).";
const USAGE: &str = "{} [OPTION]... [USERNAME]...";
#[derive(Debug)] #[derive(Debug)]
enum GroupsError { enum GroupsError {