Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: enable global flag for all commands/options #1875

Merged
merged 3 commits into from
Apr 24, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions bin/sozo/src/commands/options/transaction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,19 @@ use starknet::core::types::FieldElement;
#[derive(Debug, Args)]
#[command(next_help_heading = "Transaction options")]
pub struct TransactionOptions {
#[arg(long)]
#[arg(value_name = "MULTIPLIER")]
#[arg(long, value_name = "MULTIPLIER")]
#[arg(help = "The multiplier to use for the fee estimate.")]
#[arg(long_help = "The multiplier to use for the fee estimate. This value will be used on \
the estimated fee which will be used as the max fee for the transaction. \
(max_fee = estimated_fee * multiplier)")]
#[arg(conflicts_with = "max_fee_raw")]
#[arg(global = true)]
pub fee_estimate_multiplier: Option<f64>,

#[arg(short, long)]
#[arg(help = "Maximum raw value to be used for fees, in Wei.")]
#[arg(conflicts_with = "fee_estimate_multiplier")]
#[arg(global = true)]
pub max_fee_raw: Option<FieldElement>,

#[arg(short, long)]
Expand All @@ -25,14 +26,14 @@ pub struct TransactionOptions {
#[arg(long_help = "Wait until the transaction is accepted by the sequencer, returning the \
status and the hash. This will poll the transaction status until it gets \
accepted or rejected by the sequencer.")]
#[arg(global = true)]
pub wait: bool,

#[arg(short, long)]
#[arg(
help = "If --wait is set, returns the full transaction receipt. Otherwise, it is a no-op."
)]
#[arg(long_help = "If --wait is set, returns the full transaction receipt. Otherwise, it is \
a no-op.")]
#[arg(global = true)]
pub receipt: bool,
}

Expand Down
Loading