/** * CLAUDE.md Sync * * CLAUDE.md 파일을 파싱하여 섹션별 메모리를 생성/업데이트합니다. * * 동작: * 1. CLAUDE.md 파일 탐색 (프로젝트 루트, .claude/ 등) * 2. 마크다운 헤딩(##) 기준으로 섹션 분리 * 3. Parent-Child 패턴: 파일 전체 → Parent, 섹션별 → Child * 4. content hash로 중복/변경 감지 */ import type { MemoryDatabase } from '../db/database.js'; import type { MemoryCategory } from '../types/index.js'; export interface ClaudeSyncOptions { /** CLAUDE.md 경로 (없으면 자동 탐색) */ claudeMdPath?: string; /** 동기화할 파일명 (기본: 'CLAUDE.md') */ fileName?: string; /** dry-run 모드 */ dryRun?: boolean; /** 변경 없어도 강제 동기화 */ force?: boolean; /** 프로젝트 경로 (없으면 cwd) */ projectPath?: string; } export interface ClaudeSyncResult { found: boolean; filePath: string; totalSections: number; created: number; updated: number; skipped: number; sections: SectionResult[]; } export interface SectionResult { title: string; category: MemoryCategory; action: 'created' | 'updated' | 'skipped'; } interface ParsedSection { title: string; content: string; level: number; hash: string; } /** * Claude auto-memory 파일 여부 판별 * * 감지 대상: * - ~/.claude/projects/{hash}/memory/*.md (auto memory 파일) * - {project}/CLAUDE.md (프로젝트 루트) */ export declare function isClaudeMemoryFile(filePath: string): boolean; /** * Markdown 파일 동기화 (CLAUDE.md, AGENTS.md, GEMINI.md 등) */ export declare function syncClaudeMd(db: MemoryDatabase, options?: ClaudeSyncOptions): Promise; /** * Markdown 파일 탐색 (범용) */ export declare function findMarkdownFile(projectPath?: string, fileName?: string): string | null; /** * CLAUDE.md 파일 탐색 (하위호환) */ export declare function findClaudeMd(projectPath?: string): string | null; /** * CLAUDE.md를 섹션으로 파싱 */ export declare function parseClaudeMd(content: string): ParsedSection[]; export {}; //# sourceMappingURL=sync.d.ts.map