singularity-forge/src
TÂCHES 54df619891 feat: task isolation for subagent filesystem safety (#254)
* feat: add task isolation for subagent filesystem safety

Subagents can run in isolated git worktrees (or FUSE overlays on Linux)
so concurrent tasks don't stomp on each other's files. Changes are
captured as unified diffs and merged back via git apply.

- New isolation.ts module with worktree and FUSE overlay backends
- TaskIsolationSettings in settings-manager (mode + merge strategy)
- isolated parameter on the subagent tool schema
- Baseline capture/apply mirrors the parent repo's dirty state
- Process exit handler for best-effort cleanup of stale worktrees

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* fix: correct delta capture to exclude parent baseline state

The worktree backend now commits a baseline snapshot after applying the
parent's dirty state, so captureDeltaPatch diffs only the subagent's
actual changes against the post-baseline HEAD (not the original HEAD).

The FUSE overlay backend tracks the parent's dirty file set at mount
time and filters the upper dir during delta capture to exclude inherited
dirty files.

Also removes dead code: findGitRoot (unused), readIsolationMergeStrategy
(exported but never called).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 16:10:55 -06:00
..
resources feat: task isolation for subagent filesystem safety (#254) 2026-03-13 16:10:55 -06:00
tests feat: add startup update check with 24h cache 2026-03-13 14:28:43 -03:00
app-paths.ts Initial commit 2026-03-10 22:28:37 -06:00
cli.ts feat: add gsd update subcommand for self-update 2026-03-13 18:47:33 -03:00
loader.ts feat: async background jobs extension (#260) 2026-03-13 16:01:30 -06:00
logo.ts fix: abort squash-merge on conflict and stop auto-mode instead of looping (#merge-bug-fix) 2026-03-12 15:32:39 -06:00
onboarding.ts fix: show 'keep current' option in config when already authenticated (#283) 2026-03-13 16:04:35 -06:00
pi-migration.ts Merge pull request #151 from dbachelder/fix/pi-provider-reuse-and-extension-loading 2026-03-12 22:25:15 -06:00
resource-loader.ts Merge pull request #151 from dbachelder/fix/pi-provider-reuse-and-extension-loading 2026-03-12 22:25:15 -06:00
tool-bootstrap.ts fix: bootstrap managed tools and gh auth 2026-03-11 10:52:45 -06:00
update-check.ts feat: add startup update check with 24h cache 2026-03-13 14:28:43 -03:00
update-cmd.ts feat: add gsd update subcommand for self-update 2026-03-13 18:47:33 -03:00
wizard.ts feat: vendor Pi source into workspace monorepo 2026-03-12 21:55:17 -06:00