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

Function exec_subcommand

crates/cli/src/subcommands/server.rs:122–139  ·  view source on GitHub ↗
(
    config: Config,
    paths: &SpacetimePaths,
    cmd: &str,
    args: &ArgMatches,
)

Source from the content-addressed store, hash-verified

120}
121
122async fn exec_subcommand(
123 config: Config,
124 paths: &SpacetimePaths,
125 cmd: &str,
126 args: &ArgMatches,
127) -> Result<(), anyhow::Error> {
128 match cmd {
129 "list" => exec_list(config, args).await,
130 "set-default" => exec_set_default(config, args).await,
131 "add" => exec_add(config, args).await,
132 "remove" => exec_remove(config, args).await,
133 "fingerprint" => exec_fingerprint(config, args).await,
134 "ping" => exec_ping(config, args).await,
135 "edit" => exec_edit(config, args).await,
136 "clear" => exec_clear(config, paths, args).await,
137 unknown => Err(anyhow::anyhow!("Invalid subcommand: {unknown}")),
138 }
139}
140
141#[derive(Tabled)]
142#[tabled(rename_all = "UPPERCASE")]

Callers 1

execFunction · 0.70

Calls 9

exec_listFunction · 0.85
exec_set_defaultFunction · 0.85
exec_addFunction · 0.85
exec_removeFunction · 0.85
exec_fingerprintFunction · 0.85
exec_pingFunction · 0.85
exec_editFunction · 0.85
exec_clearFunction · 0.85
ErrFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…