Skip to content

Fix live reload after atomic saves#11

Closed
orange2ai wants to merge 1 commit into
mainfrom
fix/atomic-save-live-reload-local
Closed

Fix live reload after atomic saves#11
orange2ai wants to merge 1 commit into
mainfrom
fix/atomic-save-live-reload-local

Conversation

@orange2ai

Copy link
Copy Markdown
Collaborator

Summary

  • handle atomic-save workflows that emit rename when replacing the watched markdown file
  • re-establish the watcher after the replacement lands
  • clear pending debounce and rewatch timers when rotating watchers

Why

This addresses the core live reload problem from #1 and overlaps with the intent of #8. Editors and agents often save by writing a temp file and renaming it into place; the old watcher can stay attached to the replaced inode, so subsequent external updates stop refreshing ColaMD.

Testing

  • npm run build

Closes #1

@orange2ai

Copy link
Copy Markdown
Collaborator Author

Closing this PR to abandon the attempted fix and keep the repository state clean.

@orange2ai orange2ai closed this May 25, 2026
@orange2ai
orange2ai deleted the fix/atomic-save-live-reload-local branch May 25, 2026 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] 文件被外部修改后 ColaMD 未实时刷新

1 participant