MCPcopy Create free account
hub / github.com/clockworklabs/SpacetimeDB / cli

Function cli

crates/cli/src/subcommands/delete.rs:15–32  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

13use tokio::io::AsyncWriteExt as _;
14
15pub fn cli() -> clap::Command {
16 clap::Command::new("delete")
17 .about("Deletes a SpacetimeDB database")
18 .arg(
19 Arg::new("database")
20 .required(false)
21 .help("The name or identity of the database to delete"),
22 )
23 .arg(common_args::server().help("The nickname, host name or URL of the server hosting the database"))
24 .arg(common_args::yes())
25 .arg(
26 Arg::new("no_config")
27 .long("no-config")
28 .action(clap::ArgAction::SetTrue)
29 .help("Ignore spacetime.json configuration"),
30 )
31 .after_help("Run `spacetime help delete` for more detailed information.\n")
32}
33
34pub async fn exec(mut config: Config, args: &ArgMatches) -> Result<(), anyhow::Error> {
35 let server_from_cli = args.get_one::<String>("server").map(|s| s.as_ref());

Callers

nothing calls this directly

Calls 4

serverFunction · 0.85
yesFunction · 0.85
requiredMethod · 0.80
newFunction · 0.50

Tested by

no test coverage detected