From d1ee677591bd5e6e8b1726b2281621adf6131332 Mon Sep 17 00:00:00 2001 From: haoyuren <13851610112@163.com> Date: Sun, 15 Mar 2026 04:27:43 -0500 Subject: v0.3.0: Fix sync exclusions, add editor zoom, cached PDF loading MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Exclude CLAUDE.md from sync (move to .claude/ dotfile dir, clean up root copy) - Add Ctrl+wheel font zoom for editor (capture phase, disable Electron built-in zoom) - Load cached PDF on project connect (avoid recompile to see last PDF) - Add synctex debug logging for PDF↔source navigation troubleshooting - Fix .claude/ dir creation order (mkdir before write) Co-Authored-By: Claude Opus 4.6 --- src/main/fileSyncBridge.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'src/main/fileSyncBridge.ts') diff --git a/src/main/fileSyncBridge.ts b/src/main/fileSyncBridge.ts index fb45208..7d7274a 100644 --- a/src/main/fileSyncBridge.ts +++ b/src/main/fileSyncBridge.ts @@ -138,7 +138,8 @@ export class FileSyncBridge { atomic: true, ignored: [ /(^|[/\\])\../, // dotfiles - /\.(aux|log|fls|fdb_latexmk|synctex\.gz|bbl|blg|out|toc|lof|lot|nav|snm|vrb|pdf|pdfxref|stderr|stdout|chktex)$/ // LaTeX output files + /\.(aux|log|fls|fdb_latexmk|synctex\.gz|bbl|blg|out|toc|lof|lot|nav|snm|vrb|pdf|pdfxref|stderr|stdout|chktex)$/, // LaTeX output files + /(?:^|[/\\])(?:CLAUDE\.md|\.mcp\.json)$/ // App-generated config files ] }) @@ -449,6 +450,10 @@ export class FileSyncBridge { private onFileChanged(relPath: string): void { if (this.stopped) return + // Skip app-generated config files that should not be synced to Overleaf + const basename = relPath.split('/').pop() || relPath + if (basename === 'CLAUDE.md' || basename === '.mcp.json') return + // Layer 1: Skip if bridge is currently writing this file if (this.writesInProgress.has(relPath)) { bridgeLog(`[FileSyncBridge] skipping ${relPath} (write in progress)`) @@ -831,9 +836,10 @@ export class FileSyncBridge { for (const relPath of allFiles) { if (this.pathDocMap[relPath] || this.pathFileRefMap[relPath]) continue - // Skip LaTeX output files + // Skip LaTeX output files and app-generated config files if (/\.(aux|log|fls|fdb_latexmk|synctex\.gz|bbl|blg|out|toc|lof|lot|nav|snm|vrb|pdf|pdfxref|stderr|stdout|chktex|synctex)/.test(relPath)) continue if (/(^|[/\\])\./.test(relPath)) continue + if (/(?:^|[/\\])(?:CLAUDE\.md|\.mcp\.json)$/.test(relPath)) continue bridgeLog(`[FileSyncBridge] orphaned file found: ${relPath}`) this.onNewLocalFile(relPath) @@ -850,9 +856,10 @@ export class FileSyncBridge { if (this.stopped) return if (this.writesInProgress.has(relPath)) return - // Skip LaTeX output files and dotfiles (same as chokidar ignored) + // Skip LaTeX output files, dotfiles, and app-generated config files (same as chokidar ignored) if (/\.(aux|log|fls|fdb_latexmk|synctex\.gz|bbl|blg|out|toc|lof|lot|nav|snm|vrb|pdf|pdfxref|stderr|stdout|chktex)$/.test(relPath)) return if (/(^|[/\\])\./.test(relPath)) return + if (/(?:^|[/\\])(?:CLAUDE\.md|\.mcp\.json)$/.test(relPath)) return // Debounce 1s to let the tool finish writing const key = 'new:' + relPath -- cgit v1.2.3