MCPcopy
hub / github.com/Fission-AI/OpenSpec / validate

Method validate

src/core/init.ts:190–201  ·  view source on GitHub ↗
(
    projectPath: string,
    openspecPath: string
  )

Source from the content-addressed store, hash-verified

188 // ═══════════════════════════════════════════════════════════
189
190 private async validate(
191 projectPath: string,
192 openspecPath: string
193 ): Promise<boolean> {
194 const extendMode = await FileSystemUtils.directoryExists(openspecPath);
195
196 // Check write permissions
197 if (!(await FileSystemUtils.ensureWritePermissions(projectPath))) {
198 throw new Error(`Insufficient permissions to write to ${projectPath}`);
199 }
200 return extendMode;
201 }
202
203 private canPromptInteractively(): boolean {
204 if (this.interactiveOption === false) return false;

Callers 3

executeMethod · 0.95
index.tsFile · 0.45

Calls 2

directoryExistsMethod · 0.80

Tested by

no test coverage detected