mirror of
https://github.com/getpaseo/paseo.git
synced 2026-07-29 12:01:31 +00:00
Checkout-diff watch targets were per-Session, so multiple clients (phone, desktop, browser) watching the same workspace duplicated fs.watch sets and snapshot computation. Move all checkout-diff subscription machinery into a singleton CheckoutDiffManager that deduplicates watchers and snapshots across sessions — same pattern as AgentManager. Session now keeps only a Map<subscriptionId, unsubscribe> and thin message handler wrappers. Shared utilities (resolveCheckoutGitDir, toCheckoutError, READ_ONLY_GIT_ENV) extracted to checkout-git-utils.ts.