MCPcopy
hub / github.com/rpamis/comet / resolveAction

Function resolveAction

src/commands/init.ts:157–166  ·  view source on GitHub ↗
(
  hasExisting: boolean,
  options: InitOptions,
)

Source from the content-addressed store, hash-verified

155}
156
157function resolveAction(
158 hasExisting: boolean,
159 options: InitOptions,
160): 'overwrite' | 'skip' | 'install' {
161 if (!hasExisting) return 'install';
162 if (options.overwrite) return 'overwrite';
163 if (options.skipExisting) return 'skip';
164 if (options.yes) return 'skip';
165 return 'install';
166}
167
168type NpmDepId = 'openspec' | 'superpowers' | 'codegraph';
169

Callers 1

initCommandFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected