1 unstable release

0.1.0 Feb 8, 2022

#1322 in Game dev

Download history 8/week @ 2024-07-22 9/week @ 2024-07-29 14/week @ 2024-08-05 20/week @ 2024-09-23 6/week @ 2024-09-30 8/week @ 2024-10-07 1/week @ 2024-10-14 20/week @ 2024-10-21 8/week @ 2024-10-28 23/week @ 2024-11-04

53 downloads per month

MIT/Apache

4KB

bevy_clap

A bevy plugin to parse command line arguments with clap.

Usage

#[derive(clap::Parser)]
#[clap(name = "demo")]
struct Context {
   /// More verbose output
   #[clap(long)]
   verbose: bool,
   /// An optional name
   #[clap(short, long)]
   name: Option<String>,
}

fn main() {
    App::new()
        // ...
        .add_plugin(ClapPlugin::<Context>::default())
        // ...
        .run();
}

The Context value will be added as a clap resource on startup.


lib.rs:

bevy_clap

Dependencies

~19–35MB
~589K SLoC