MCPcopy Create free account
hub / github.com/CreminiAI/skillpack / ensureFile

Method ensureFile

src/runtime/config.ts:370–378  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

368
369/**
370 * Custom AuthStorageBackend that persists OAuth credentials to the `_auth`
371 * field of config.json, keeping all configuration in a single file.
372 */
373export class ConfigFileAuthBackend implements AuthStorageBackend {
374 constructor(private configPath: string) {}
375
376 private ensureFile(): void {
377 const dir = path.dirname(this.configPath);
378 if (!fs.existsSync(dir)) {
379 fs.mkdirSync(dir, { recursive: true });
380 }
381 if (!fs.existsSync(this.configPath)) {

Callers 2

readAuthJsonMethod · 0.95
writeAuthJsonMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected