MCPcopy Create free account
hub / github.com/backnotprop/plannotator / getPlanDir

Function getPlanDir

packages/shared/storage.ts:23–34  ·  view source on GitHub ↗
(customPath?: string | null)

Source from the content-addressed store, hash-verified

21 * @param customPath Optional custom path. Supports ~ for home directory.
22 */
23export function getPlanDir(customPath?: string | null): string {
24 let planDir: string;
25
26 if (customPath?.trim()) {
27 planDir = resolveUserPath(customPath);
28 } else {
29 planDir = join(DATA_DIR, "plans");
30 }
31
32 mkdirSync(planDir, { recursive: true });
33 return planDir;
34}
35
36/**
37 * Extract the first heading from markdown content.

Callers 6

storage.test.tsFile · 0.90
savePlanFunction · 0.85
saveAnnotationsFunction · 0.85
saveFinalSnapshotFunction · 0.85
listArchivedPlansFunction · 0.85
readArchivedPlanFunction · 0.85

Calls 1

resolveUserPathFunction · 0.90

Tested by

no test coverage detected