mod download;
mod list;
pub use download::*;
pub use list::*;
use crate::CommandContext;
use clap::Subcommand;
use mithril_client::MithrilResult;
#[derive(Subcommand, Debug, Clone)]
#[command(about = "Cardano stake distribution management (alias: csd)")]
pub enum CardanoStakeDistributionCommands {
#[clap(arg_required_else_help = false)]
List(CardanoStakeDistributionListCommand),
#[clap(arg_required_else_help = true)]
Download(CardanoStakeDistributionDownloadCommand),
}
impl CardanoStakeDistributionCommands {
pub async fn execute(&self, config_builder: CommandContext) -> MithrilResult<()> {
match self {
Self::List(cmd) => cmd.execute(config_builder).await,
Self::Download(cmd) => cmd.execute(config_builder).await,
}
}
}