soroban-cli 26.0.0

Soroban CLI
Documentation
use crate::config::address::NetworkName;

use super::locator;

#[derive(thiserror::Error, Debug)]
pub enum Error {
    #[error(transparent)]
    Locator(#[from] locator::Error),
}

#[derive(Debug, clap::Parser, Clone)]
#[group(skip)]
pub struct Cmd {
    /// Network to remove
    pub name: NetworkName,

    #[command(flatten)]
    pub config: locator::Args,
}

impl Cmd {
    pub fn run(&self) -> Result<(), Error> {
        Ok(self.config.remove_network(&self.name)?)
    }
}