mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-08-01 13:37:48 +00:00
groups: clap 3
This commit is contained in:
parent
ebe96f1454
commit
742fe8500c
2 changed files with 5 additions and 5 deletions
|
@ -17,7 +17,7 @@ path = "src/groups.rs"
|
|||
[dependencies]
|
||||
uucore = { version=">=0.0.10", package="uucore", path="../../uucore", features=["entries", "process"] }
|
||||
uucore_procs = { version=">=0.0.7", package="uucore_procs", path="../../uucore_procs" }
|
||||
clap = { version = "2.33", features = ["wrap_help"] }
|
||||
clap = { version = "3.0", features = ["wrap_help", "cargo"] }
|
||||
|
||||
[[bin]]
|
||||
name = "groups"
|
||||
|
|
|
@ -73,7 +73,7 @@ fn infallible_gid2grp(gid: &u32) -> String {
|
|||
pub fn uumain(args: impl uucore::Args) -> UResult<()> {
|
||||
let usage = usage();
|
||||
|
||||
let matches = uu_app().usage(&usage[..]).get_matches_from(args);
|
||||
let matches = uu_app().override_usage(&usage[..]).get_matches_from(args);
|
||||
|
||||
let users: Vec<String> = matches
|
||||
.values_of(options::USERS)
|
||||
|
@ -105,13 +105,13 @@ pub fn uumain(args: impl uucore::Args) -> UResult<()> {
|
|||
Ok(())
|
||||
}
|
||||
|
||||
pub fn uu_app() -> App<'static, 'static> {
|
||||
pub fn uu_app<'a>() -> App<'a> {
|
||||
App::new(uucore::util_name())
|
||||
.version(crate_version!())
|
||||
.about(ABOUT)
|
||||
.arg(
|
||||
Arg::with_name(options::USERS)
|
||||
.multiple(true)
|
||||
Arg::new(options::USERS)
|
||||
.multiple_occurrences(true)
|
||||
.takes_value(true)
|
||||
.value_name(options::USERS),
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue