/** * Filesystem utilities with atomic operations and Windows safety */ /** * Get the cache directory for claudebase * Cross-platform: ~/.claudebase/cache on Unix, %LOCALAPPDATA%\claudebase\cache on Windows */ export declare function getCacheDir(): string; /** * Get the plugin installation directory * This is where Claude Code expects plugins: ~/.claude/plugins */ export declare function getPluginDir(): string; /** * Get the manifest file path */ export declare function getManifestPath(): string; /** * Ensure directory exists with user-only permissions (v1 security contract) */ export declare function ensureDir(dir: string): Promise; /** * Check if path exists */ export declare function exists(path: string): Promise; /** * Read file as string */ export declare function readFile(path: string): Promise; /** * Read file as buffer */ export declare function readFileBuffer(path: string): Promise; /** * Write file atomically (write to temp, then rename) * Sets user-only permissions (v1 security contract) */ export declare function writeFileAtomic(path: string, content: string | Buffer): Promise; /** * Atomic rename with Windows retry logic */ export declare function atomicRename(src: string, dest: string): Promise; /** * Remove directory recursively */ export declare function removeDir(dir: string): Promise; /** * Remove file */ export declare function removeFile(path: string): Promise; /** * Copy directory recursively */ export declare function copyDir(src: string, dest: string): Promise; /** * Get temp directory for staging */ export declare function getTempDir(): string; /** * List files in directory */ export declare function listFiles(dir: string): Promise; /** * Read JSON file with type safety */ export declare function readJson(path: string): Promise; /** * Write JSON file atomically */ export declare function writeJson(path: string, data: unknown): Promise; //# sourceMappingURL=fs.d.ts.map