Skip to content

Navigation Menu

Sign in
Sign up

feat: copy build directories between worktrees - #670

Open
matt2e wants to merge 1 commit into
main from
copy-build-dir
Open

feat: copy build directories between worktrees #670
matt2e wants to merge 1 commit into
main from
copy-build-dir

Conversation

@matt2e

@matt2e matt2e commented Apr 30, 2026

Copy link
Copy Markdown
Contributor

Adds experimental build directory copying between worktrees with APFS cloning, recursive whitelist discovery, settings UI, and persisted opt-in state.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a9d5178821

i️ About Codex in GitHub

Codex has been enabled to automatically 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 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +654 to +656
await commands.setCopyBuildDirsEnabled(selectedContext.id, enabled);
contexts = contexts.map((c) =>
c.id === selectedContext!.id ? { ...c, copyBuildDirsEnabled: enabled } : c

@chatgpt-codex-connector chatgpt-codex-connector Bot Apr 30, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Capture context ID before awaiting checkbox update

The onchange handler reads selectedContext again after await commands.setCopyBuildDirsEnabled(...), so if the user switches to another repo context before the promise resolves, the post-await contexts.map(...) can update the wrong context (or throw if selection becomes null). This makes the UI reflect an incorrect toggle state for a different repo context; capture the original contextId in a local variable before await and use that for both the command and state update.

Useful? React with 👍 / 👎.

matt2e force-pushed the copy-build-dir branch 2 times, most recently from e3058c6 to 5b420ae Compare May 5, 2026 04:51
Copy whitelisted, gitignored build/cache directories from the last-run worktree when creating a new worktree. Discover build directories with a bounded recursive walk, use CoW-friendly copy commands where available, and keep the feature opt-in behind an experimental repo setting.
Track last-run worktrees in the store, place this branch's store migrations after origin/main's pipeline migration as versions 15 and 16, and update migration tests/bootstrap expectations to schema version 16.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Matt Toohey <contact@matttoohey.com>
Signed-off-by: Test <test@example.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@chatgpt-codex-connector chatgpt-codex-connector[bot] chatgpt-codex-connector[bot] left review comments
@baxen baxen Awaiting requested review from baxen baxen is a code owner
@wesbillman wesbillman Awaiting requested review from wesbillman wesbillman is a code owner

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /