MCPcopy Create free account
hub / github.com/Microck/opencode-studio / saveCommand

Function saveCommand

client-next/src/lib/api.ts:350–360  ·  view source on GitHub ↗
(name: string, template: string)

Source from the content-addressed store, hash-verified

348}
349
350export async function saveCommand(name: string, template: string): Promise<void> {
351 const config = await getConfig();
352 const updated = {
353 ...config,
354 command: {
355 ...config.command,
356 [name]: { template }
357 }
358 };
359 await saveConfig(updated);
360}
361
362export async function deleteCommand(name: string): Promise<void> {
363 const config = await getConfig();

Callers 3

handleAddFunction · 0.90
handleEditSaveFunction · 0.90
handleSaveFunction · 0.90

Calls 2

getConfigFunction · 0.85
saveConfigFunction · 0.70

Tested by

no test coverage detected