Merge pull request #244 from benthecarman/positial-args

refactor: require named arguments for CreateOffer CLI options
This commit is contained in:
Maurice Poirrier 2025-10-01 14:56:58 +02:00 committed by GitHub
commit 406b2a08f9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -184,20 +184,20 @@ enum Commands {
/// CreateOffer creates a BOLT 12 offer.
CreateOffer {
/// The amount of the offer in millisatoshis.
#[arg(required = false)]
#[arg(long, required = false)]
amount: Option<u64>,
/// The description of the offer.
#[arg(required = false)]
#[arg(long, required = false)]
description: Option<String>,
/// The issuer of the offer.
#[arg(required = false)]
#[arg(long, required = false)]
issuer: Option<String>,
/// Relative expiry of the offer in seconds.
#[arg(required = false)]
#[arg(long, required = false)]
expiry: Option<u64>,
/// The quantity of the offer. If 0, unbounded quantity is assumed. If None,
/// quantity defaults to 1.
#[arg(required = false)]
#[arg(long, required = false)]
quantity: Option<u64>,
},
}