soroban_cli/commands/snapshot/
mod.rs

1use clap::Parser;
2
3use super::global;
4
5pub mod create;
6
7/// Create and operate on ledger snapshots.
8#[derive(Debug, Parser)]
9pub enum Cmd {
10    Create(create::Cmd),
11}
12
13#[derive(thiserror::Error, Debug)]
14pub enum Error {
15    #[error(transparent)]
16    Create(#[from] create::Error),
17}
18
19impl Cmd {
20    pub async fn run(&self, global_args: &global::Args) -> Result<(), Error> {
21        match self {
22            Cmd::Create(cmd) => cmd.run(global_args).await?,
23        }
24        Ok(())
25    }
26}