MCPcopy Create free account
hub / github.com/cortexkit/magic-context / ensureDir

Function ensureDir

packages/cli/src/commands/setup-opencode.ts:27–31  ·  view source on GitHub ↗
(dir: string)

Source from the content-addressed store, hash-verified

25// ─── Helpers ──────────────────────────────────────────────
26
27function ensureDir(dir: string): void {
28 if (!existsSync(dir)) {
29 mkdirSync(dir, { recursive: true });
30 }
31}
32
33function readJsonc(path: string): Record<string, unknown> | null {
34 const content = readFileSync(path, "utf-8");

Callers 2

addPluginToTuiConfigFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected