feat(server): support symlink worktree includes#2419
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 961b8e07b4
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7cc6cdb118
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 07ef5cee67
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
b51af60 to
1a86a99
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 45cb4bb57a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: dce2ae5ffe
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Closes #2420.
Problem
Git worktrees contain tracked files, but local ignored files and directories such as environment files, credentials, and caches are absent. Paseo setup scripts can copy them manually, but that duplicates boilerplate and cannot express intentionally shared state without hand-written platform-specific links.
What changed
.worktreeincludesupport beforeworktree.setupcopy <path>/symlink <path>modes*,**, anddirectory/**pattern semantics explored in feat(server): support worktree include files #1772copymakes a snapshot of that target, whilesymlinkcreates one direct live link to it rather than a link-to-link; hard links remain ordinary filesExample:
The verb-prefix form follows an existing public
.worktreeincludeimplementation in nubjs/nub. Bare entries remain copy-compatible.Policy
An include may read only from the active source checkout. If that checkout is itself Paseo-managed, its own paths remain eligible; sibling and external managed-worktree paths remain protected. External or dangling symlinks, traversal,
.git, special files, and destination-link escapes are not materialized. A safe entry is never blocked by an unrelated include failure. Paseo removes staged output for a failed entry and continues; it aborts only when it cannot safely restore or clean up partial state.Prior discussion
Inspired by and intended to supersede the abandoned copy-only implementation in #1772.
QA
Focused local macOS verification:
npx vitest run packages/server/src/utils/worktree-include.test.ts --bail=1 --reporter=verbose— 17 passed, 1 Windows-only test skippednpx vitest run packages/server/src/utils/worktree.posix.test.ts --bail=1 --reporter=verbose— 49 passed, 1 macOS-only test skippednpm run typechecknpm run lint -- ...npm run format:checkWindows link behavior retains host-gated real-filesystem coverage but was not exercised locally; CI should run that case on Windows.