MCPcopy Create free account
hub / github.com/MatterAIOrg/OrbCode / runRemove

Function runRemove

src/commands/mcp.ts:270–285  ·  view source on GitHub ↗

`orbcode mcp remove ` — remove from whichever scope it's in.

(args: string[])

Source from the content-addressed store, hash-verified

268
269/** `orbcode mcp remove <name>` — remove from whichever scope it's in. */
270function runRemove(args: string[]): number {
271 if (args.length === 0) {
272 console.error("Missing server name. Usage: orbcode mcp remove <name>")
273 return 1
274 }
275 const name = args[0]!
276 const scope = removeMcpServerAnyScope(process.cwd(), name)
277 if (!scope) {
278 console.error(`MCP server "${name}" not found in any scope.`)
279 return 1
280 }
281 const filePath = configPathForScope(process.cwd(), scope)
282 console.log(`Removed MCP server "${name}" from ${scope} scope.`)
283 console.log(` File modified: ${filePath}`)
284 return 0
285}
286
287/** `orbcode mcp list` — print all configured servers with their scope + status. */
288function runList(_args: string[]): number {

Callers 1

runMcpCommandFunction · 0.85

Calls 2

removeMcpServerAnyScopeFunction · 0.85
configPathForScopeFunction · 0.85

Tested by

no test coverage detected