31 releases (17 breaking)

0.18.3 Oct 22, 2025
0.17.1 Sep 8, 2025
0.16.0 Jul 12, 2025
0.15.2 Jan 14, 2025
0.1.4 May 23, 2019

#3 in Cargo plugins

Download history 108996/week @ 2025-10-17 111122/week @ 2025-10-24 126485/week @ 2025-10-31 129807/week @ 2025-11-07 128442/week @ 2025-11-14 122744/week @ 2025-11-21 116149/week @ 2025-11-28 116778/week @ 2025-12-05 121883/week @ 2025-12-12 93120/week @ 2025-12-19 94042/week @ 2025-12-26 123284/week @ 2026-01-02 118897/week @ 2026-01-09 119439/week @ 2026-01-16 133127/week @ 2026-01-23 150082/week @ 2026-01-30

541,857 downloads per month
Used in 208 crates (132 directly)

MIT/Apache

39KB
622 lines

clap-cargo

Re-usable CLI flags for cargo plugins

codecov Documentation License Crates Status

Examples

// ...
#[derive(Debug, clap::Parser)]
#[command(styles = clap_cargo::style::CLAP_STYLING)]
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
~32K SLoC