#plugin #cargo #clap #flatten

clap-cargo

Re-usable CLI flags for cargo plugins

24 releases (14 breaking)

0.15.2 Jan 14, 2025
0.14.1 Jul 25, 2024
0.14.0 Feb 6, 2024
0.13.0 Oct 2, 2023
0.1.4 May 23, 2019

#2 in Cargo plugins

Download history 46871/week @ 2025-01-29 47563/week @ 2025-02-05 49106/week @ 2025-02-12 57449/week @ 2025-02-19 50784/week @ 2025-02-26 52267/week @ 2025-03-05 55980/week @ 2025-03-12 70497/week @ 2025-03-19 56160/week @ 2025-03-26 79995/week @ 2025-04-02 71985/week @ 2025-04-09 74718/week @ 2025-04-16 74859/week @ 2025-04-23 80733/week @ 2025-04-30 79957/week @ 2025-05-07 65613/week @ 2025-05-14

313,242 downloads per month
Used in 148 crates (98 directly)

MIT/Apache

34KB
566 lines

clap-cargo

Re-usable CLI flags for cargo plugins

codecov Documentation License Crates Status

Examples

// ...
#[derive(Debug, clap::Parser)]
struct Cli {
    #[command(flatten)]
    manifest: clap_cargo::Manifest,
    #[command(flatten)]
    workspace: clap_cargo::Workspace,
    #[command(flatten)]
    features: clap_cargo::Features,
}

Relevant crates

Other crates that might be useful for cargo plugins:

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~1–1.8MB
~34K SLoC