| Crates.io | clowncopterize |
| lib.rs | clowncopterize |
| version | 0.0.2 |
| created_at | 2025-04-01 21:38:41.37723+00 |
| updated_at | 2025-04-04 04:45:58.756677+00 |
| description | A clown to rule them all! |
| homepage | https://github.com/chantra/clowncopterize |
| repository | https://github.com/chantra/clowncopterize |
| max_upload_size | |
| id | 1615643 |
| size | 19,777 |
clowncopterize is a tool to make setting all clowntown cli arguments easier.
The clowntown command line argument is a well-known reliability feature that allows to hide risky features behind a flag. As reliability
is taken more and more seriously, the sprawling of clowntown flags is becoming an issue for our savvy engineer who are ending up writing
command lines that goes beyond our cherrished 80-char limits.
To make people's life easier, here comes clowncopterize! With a single line added to your program, you can achieve the apex of reliability
by providing the almighty --clowncopterize argument which will set all your --clowntown-X flags to true.
clowncopterize is an attribute macro to apply to a clap struct to make it easier to set all those --clowntown-X flags with a single --clowncopterize flag.
Wrap you clap Parser struct with
#[clowncopterize::clowncopterize]
This macro must be above the derive one.
#[clowncopterize::clowncopterize]
#[derive(Parser, Debug)]
struct Cli {
/// Optional name to operate on
name: Option<String>,
/// Turn debugging information on
#[arg(long)]
clowntown_this: bool,
/// lists test values
#[arg(long)]
clowntown_that: bool,
}
License: MIT