feat(cli): alias gen for generate subcommand + add -l / -w short flags
clap alias makes both `relicario gen -l 32` and the long-form `relicario generate -l 32` route to the same handler. The short flags -l (length) and -w (words) were missing -- the READMEs existing example `relicario generate -l 32` only actually worked after this commit. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -140,12 +140,13 @@ enum Commands {
|
||||
/// vault, falls back to `settings generator-defaults` for unspecified
|
||||
/// flags; outside a vault, uses built-in defaults (length 20, safe
|
||||
/// symbol set, 5 BIP39 words, space separator).
|
||||
#[command(alias = "gen")]
|
||||
Generate {
|
||||
#[arg(long)]
|
||||
#[arg(short = 'l', long)]
|
||||
length: Option<u32>,
|
||||
#[arg(long)]
|
||||
bip39: bool,
|
||||
#[arg(long)]
|
||||
#[arg(short = 'w', long)]
|
||||
words: Option<u32>,
|
||||
#[arg(long)]
|
||||
symbols: Option<String>,
|
||||
|
||||
Reference in New Issue
Block a user