diff --git a/src/uu/yes/Cargo.toml b/src/uu/yes/Cargo.toml index 7c2b43329..b5eaa0ad6 100644 --- a/src/uu/yes/Cargo.toml +++ b/src/uu/yes/Cargo.toml @@ -15,7 +15,7 @@ edition = "2018" path = "src/yes.rs" [dependencies] -clap = { version = "2.33", features = ["wrap_help"] } +clap = { version = "3.0", features = ["wrap_help", "cargo"] } uucore = { version=">=0.0.10", package="uucore", path="../../uucore", features=["pipes"] } uucore_procs = { version=">=0.0.7", package="uucore_procs", path="../../uucore_procs" } diff --git a/src/uu/yes/src/yes.rs b/src/uu/yes/src/yes.rs index bbedc0af1..51701214a 100644 --- a/src/uu/yes/src/yes.rs +++ b/src/uu/yes/src/yes.rs @@ -46,8 +46,8 @@ pub fn uumain(args: impl uucore::Args) -> UResult<()> { } } -pub fn uu_app() -> App<'static, 'static> { - app_from_crate!().arg(Arg::with_name("STRING").index(1).multiple(true)) +pub fn uu_app<'a>() -> App<'a> { + app_from_crate!().arg(Arg::new("STRING").index(1).multiple_occurrences(true)) } fn prepare_buffer<'a>(input: &'a str, buffer: &'a mut [u8; BUF_SIZE]) -> &'a [u8] {