Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,14 @@ pubspec_overrides.yaml
.ac/
CLAUDE.local.md
.sync-agents-cache.json

# Worktrees Claude Code creates for parallel sessions and isolated subagents.
# Only this subdirectory, so anything else that lands under `.claude/` stays visible
# to git. Nothing is tracked there today.
#
# They sit inside the working tree rather than beside it. `git clean -xdf` leaves them
# alone: git's nested-repository guard resolves a gitfile too, so it reports "Skipping
# repository .claude/worktrees/<slug>" and the contents survive. `git clean -xdff` does
# not skip them, and wipes a live worktree while `.git/worktrees/<slug>` survives,
# leaving a registration that `git worktree prune` then has to clear.
.claude/worktrees/
21 changes: 21 additions & 0 deletions .worktreeinclude
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Gitignored files copied into every worktree Claude Code creates, for `--worktree`,
# for `EnterWorktree`, and for a subagent with `isolation: worktree`.
#
# A worktree is a fresh checkout, so `pubspec_overrides.yaml` is absent from it, and
# its absence fails silently rather than loudly: the siblings resolve from pub.dev
# instead of the working trees beside this one, `flutter pub get` succeeds, and the
# suite then passes against the PUBLISHED packages while the diff under review is of
# the local ones. An unreleased sibling API is where that bites.
#
# `.gitignore` syntax, and only files that match AND are gitignored are copied, so a
# tracked file can never be duplicated by this list.
#
# The paths inside `pubspec_overrides.yaml` have to be ABSOLUTE for this to work.
# Worktrees live under `.claude/worktrees/<slug>`, so a relative `../magic` resolves
# to `.claude/worktrees/magic`, which does not exist, and version solving fails on
# the first path dependency.
#
# NOT processed when a WorktreeCreate hook replaces the default git logic; such a
# hook has to copy these itself.

pubspec_overrides.yaml
4 changes: 4 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ directly is flagged as an unnecessary import.
Local sibling development goes through the gitignored `pubspec_overrides.yaml`. The committed
`pubspec.yaml` stays on hosted caret constraints so a fork outside this workspace resolves on its own.

That overrides file must use ABSOLUTE paths. `.worktreeinclude` copies it into worktrees under
`.claude/worktrees/<slug>`, where the conventional relative `../magic` resolves to
`.claude/worktrees/magic` and fails version solving on the first path dependency.

## Barrels

Four, and the split is the API:
Expand Down