Add worktree skill for git worktree lifecycle#5
Conversation
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📒 Files selected for processing (19)
📝 WalkthroughWalkthroughThe changes add a new "worktree" skill to the CodeForge skill-engine (increasing skills from 21 to 22), introduce comprehensive worktree documentation and references, update skill counts across docs and site components, and add skill-suggester detection for worktree-related prompts. System prompt guidance for worktrees is also expanded. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 11
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.devcontainer/CHANGELOG.md:
- Around line 5-11: The changelog places the "`<git_worktrees>` section" note
under "### Added" but it documents an update to existing behavior; move that
bullet (the line mentioning `"<git_worktrees>" section` and its details about
the Claude Code native worktree convention, `EnterWorktree` guidance, and
`.worktreeinclude` file documentation) from the "### Added" block into a "###
Changed" block so it correctly reflects a change rather than a new addition.
In @.devcontainer/config/defaults/main-system-prompt.md:
- Around line 341-363: The CLAUDE.md doc is missing the new worktree guidance
present in main-system-prompt.md; add a "Worktrees" section to
.devcontainer/CLAUDE.md that copies the same guidance: describe native usage
(EnterWorktree tool and the --worktree <name> flag creating
<repo>/.claude/worktrees/<name>/ with branch worktree-<name> and auto-clean
behavior), the manual legacy approach (mkdir .worktrees + git worktree add
/workspaces/projects/.worktrees/<branch-name> -b <branch>), explain
.worktreeinclude behavior (files must match .worktreeinclude and .gitignore),
list management commands (git worktree list, git worktree remove <path>, git
worktree prune) and state the path conventions (native vs legacy .worktrees/);
ensure terminology matches exactly (EnterWorktree, --worktree, .worktreeinclude,
.worktrees) so readers can map config to docs.
In
@.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/manual-worktree-commands.md:
- Around line 75-90: Add language tags (e.g., ```text) to the three fenced code
blocks that are missing them: the block starting with
"/workspaces/projects/CodeForge d2ba55e [main]" (first diff block),
the block starting with "worktree /workspaces/projects/CodeForge" (porcelain
output block), and the block containing "gitdir:
/workspaces/projects/CodeForge/.git/worktrees/feature-a"; update each opening
fence to include a language specifier like "text" so markdownlint MD040 is
satisfied.
In
@.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/parallel-workflow-patterns.md:
- Line 74: Replace the absolute statement "No merge conflicts during parallel
work" with a softened claim that reflects reality; update the phrase in the
document (the heading/text that currently reads "No merge conflicts during
parallel work") to something like "Reduces conflict risk when file ownership is
respected" or equivalent, so it no longer guarantees zero conflicts and aligns
with the caution on Line 79.
In
@.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/SKILL.md:
- Around line 39-41: Two fenced code blocks in SKILL.md (the one containing
"EnterWorktree: feature-auth-oauth2" and the block showing the worktree listing)
lack language identifiers and trigger markdownlint MD040; update both fenced
blocks to include a language tag (e.g., change ``` to ```text) so the blocks
around the "EnterWorktree: feature-auth-oauth2" snippet and the worktree listing
(lines referenced in the review, including the other block at 132-135) are
fenced as ```text.
- Line 13: The allowed-tools list is missing EnterWorktree while the document
references EnterWorktree as the primary method; update the allowed-tools entry
(the YAML key named allowed-tools) to include EnterWorktree alongside Bash,
Read, Grep, Glob so the documented primary workflow (EnterWorktree references on
lines ~35–42, 65, 85, 142, 203, 212) is permitted and consistent with the
document.
In @.devcontainer/README.md:
- Line 332: Update the General Skills list for the skill-engine plugin to
include the missing "worktree" entry so the list matches the header "General
Skills (22) — `skill-engine`"; locate the README section titled "General Skills
(22) — `skill-engine`" and insert "worktree" into the enumerated skills list
(maintain the same formatting as the other entries) and verify the total count
reflects 22 items.
In `@docs/src/content/docs/features/index.md`:
- Line 46: The Feature Summary table is inconsistent: the body text uses "**22
domain-specific knowledge packs**" but the summary row still lists "21"; update
the summary row count from 21 to 22 so the page is consistent. Locate the
"Feature Summary" table row that currently shows "21" (the summary row) and
change that cell to "22" to match the paragraph that reads "**22 domain-specific
knowledge packs**". Ensure any other occurrences of "21" in the same document
referring to the skills count are updated to "22".
In `@docs/src/content/docs/getting-started/index.md`:
- Line 8: Update the inconsistent skill count in the Getting Started doc: locate
the sentence containing "Skill Engine has 21 knowledge packs" (the line that
still reads 21) and change the number to 22 so it matches the other occurrences
(lines that say 22); ensure any nearby mentions of knowledge packs/skills in the
same paragraph are adjusted consistently.
In `@docs/src/content/docs/plugins/skill-engine.md`:
- Line 38: Update the page so the displayed skill count and tables match: change
the header sentence "CodeForge ships with 21 skills" to 22 (the lines currently
stating 22 at 38 and 174 are correct but the top-of-page count at line 3 must be
updated), add the missing "worktree" entry to the skills tables where it's
absent, and ensure any other summary counts or lists on this page reflect the
new total of 22 skills (search for the phrase "CodeForge ships with" and the
skills table blocks and update them).
In `@docs/src/content/docs/reference/architecture.md`:
- Line 149: The table row for "skill-engine/" was updated to 22 but the summary
elsewhere still reads "34 skills"; update the stale aggregate string "34 skills"
to "35 skills" so the combined total matches (search for the literal "34 skills"
in the same document and replace it with "35 skills", e.g., near the summary
paragraph that references the total skills count).
ℹ️ Review info
Configuration used: defaults
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (20)
.devcontainer/CHANGELOG.md.devcontainer/CLAUDE.md.devcontainer/README.md.devcontainer/config/defaults/main-system-prompt.md.devcontainer/docs/plugins.md.devcontainer/plugins/devs-marketplace/plugins/skill-engine/.claude-plugin/plugin.json.devcontainer/plugins/devs-marketplace/plugins/skill-engine/README.md.devcontainer/plugins/devs-marketplace/plugins/skill-engine/scripts/skill-suggester.py.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/SKILL.md.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/manual-worktree-commands.md.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/parallel-workflow-patterns.mdREADME.mddocs/src/components/Hero.astrodocs/src/content/docs/features/index.mddocs/src/content/docs/features/skills.mddocs/src/content/docs/getting-started/first-session.mddocs/src/content/docs/getting-started/index.mddocs/src/content/docs/plugins/index.mddocs/src/content/docs/plugins/skill-engine.mddocs/src/content/docs/reference/architecture.md
...devs-marketplace/plugins/skill-engine/skills/worktree/references/manual-worktree-commands.md
Outdated
Show resolved
Hide resolved
...vs-marketplace/plugins/skill-engine/skills/worktree/references/parallel-workflow-patterns.md
Outdated
Show resolved
Hide resolved
.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/SKILL.md
Outdated
Show resolved
Hide resolved
| ## Skills | ||
|
|
||
| **21 domain-specific knowledge packs** give Claude deep expertise in frameworks, patterns, and workflows. When you start discussing FastAPI routes or Svelte 5 runes, the skill engine detects the context and auto-suggests the relevant skill. Once loaded, the skill injects structured knowledge — best practices, code patterns, API references, and common pitfalls — directly into Claude's context for the current task. | ||
| **22 domain-specific knowledge packs** give Claude deep expertise in frameworks, patterns, and workflows. When you start discussing FastAPI routes or Svelte 5 runes, the skill engine detects the context and auto-suggests the relevant skill. Once loaded, the skill injects structured knowledge — best practices, code patterns, API references, and common pitfalls — directly into Claude's context for the current task. |
There was a problem hiding this comment.
Feature Summary table still has the old skills count.
Lines 46/58 say 22 skills, but the summary row at Line 93 still lists 21. Please update that row to keep the page consistent.
Suggested doc patch
-| [Skills](./skills/) | 21 | FastAPI, Svelte 5, Docker, Testing, Debugging, Security, and 15 more |
+| [Skills](./skills/) | 22 | FastAPI, Svelte 5, Docker, Testing, Debugging, Security, and 16 more |As per coding guidelines docs/**: User-facing documentation changes MUST be reflected in relevant pages in docs/ if the docs site exists.
Also applies to: 58-58
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@docs/src/content/docs/features/index.md` at line 46, The Feature Summary
table is inconsistent: the body text uses "**22 domain-specific knowledge
packs**" but the summary row still lists "21"; update the summary row count from
21 to 22 so the page is consistent. Locate the "Feature Summary" table row that
currently shows "21" (the summary row) and change that cell to "22" to match the
paragraph that reads "**22 domain-specific knowledge packs**". Ensure any other
occurrences of "21" in the same document referring to the skills count are
updated to "22".
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In
@.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/SKILL.md:
- Around line 104-107: The wording in the "Rules" section is ambiguous—reword
the `.worktreeinclude` rule so it clearly states that files listed in
`.worktreeinclude` will be copied only if they are untracked (i.e., ignored by
Git via `.gitignore`), and that tracked files are never duplicated; update the
sentence that currently reads "Only files matching both `.worktreeinclude` and
`.gitignore` are copied" to something like: "Only files listed in
`.worktreeinclude` that are untracked/ignored by Git (per `.gitignore`) are
copied; tracked files come from the checkout and are not duplicated." Ensure
this change is applied in the "Rules:" block of SKILL.md and references the
`.worktreeinclude` and `.gitignore` patterns.
- Around line 130-135: Update the example output for `git worktree list` in
SKILL.md to use the native-path-as-primary convention described earlier: replace
the legacy `.worktrees/feature-a` path with the native path format used by
EnterWorktree/--worktree (e.g., `<repo>/.claude/worktrees/<name>/feature-a`) and
keep the same HEAD/branch columns so the example matches the documented workflow
and symbols `EnterWorktree`, `--worktree`, and `git worktree list`.
ℹ️ Review info
Configuration used: defaults
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (10)
.devcontainer/CHANGELOG.md.devcontainer/CLAUDE.md.devcontainer/README.md.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/SKILL.md.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/manual-worktree-commands.md.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/parallel-workflow-patterns.mddocs/src/content/docs/features/index.mddocs/src/content/docs/getting-started/index.mddocs/src/content/docs/plugins/skill-engine.mddocs/src/content/docs/reference/architecture.md
✅ Files skipped from review due to trivial changes (2)
- .devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/parallel-workflow-patterns.md
- .devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/references/manual-worktree-commands.md
🚧 Files skipped from review as they are similar to previous changes (3)
- .devcontainer/CHANGELOG.md
- docs/src/content/docs/plugins/skill-engine.md
- .devcontainer/README.md
| **Rules:** | ||
| - Uses `.gitignore` pattern syntax | ||
| - Only files matching **both** `.worktreeinclude` and `.gitignore` are copied | ||
| - Tracked files are never duplicated (they come from the checkout itself) |
There was a problem hiding this comment.
Clarify the .worktreeinclude copy rule — "matching both" is ambiguous.
The phrase "Only files matching both .worktreeinclude and .gitignore are copied" reads as if a user must list the file in both .worktreeinclude and .gitignore to trigger copying. The actual intent is that only untracked (gitignored) files listed in .worktreeinclude are copied. Rephrasing avoids the misread:
✏️ Proposed clarification
-Only files matching **both** `.worktreeinclude` and `.gitignore` are copied
+Only untracked files (those already excluded by `.gitignore`) that are listed in `.worktreeinclude` are copied📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| **Rules:** | |
| - Uses `.gitignore` pattern syntax | |
| - Only files matching **both** `.worktreeinclude` and `.gitignore` are copied | |
| - Tracked files are never duplicated (they come from the checkout itself) | |
| **Rules:** | |
| - Uses `.gitignore` pattern syntax | |
| - Only untracked files (those already excluded by `.gitignore`) that are listed in `.worktreeinclude` are copied | |
| - Tracked files are never duplicated (they come from the checkout itself) |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In
@.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/SKILL.md
around lines 104 - 107, The wording in the "Rules" section is ambiguous—reword
the `.worktreeinclude` rule so it clearly states that files listed in
`.worktreeinclude` will be copied only if they are untracked (i.e., ignored by
Git via `.gitignore`), and that tracked files are never duplicated; update the
sentence that currently reads "Only files matching both `.worktreeinclude` and
`.gitignore` are copied" to something like: "Only files listed in
`.worktreeinclude` that are untracked/ignored by Git (per `.gitignore`) are
copied; tracked files come from the checkout and are not duplicated." Ensure
this change is applied in the "Rules:" block of SKILL.md and references the
`.worktreeinclude` and `.gitignore` patterns.
| Output shows each worktree's path, HEAD commit, and branch: | ||
|
|
||
| ```text | ||
| /workspaces/projects/CodeForge d2ba55e [main] | ||
| /workspaces/projects/.worktrees/feature-a abc1234 [feature-a] | ||
| ``` |
There was a problem hiding this comment.
git worktree list example only shows the legacy path — inconsistent with the native-path-as-primary narrative.
The example output on lines 132-135 shows a .worktrees/feature-a (legacy convention) path. A user who followed the recommended EnterWorktree/--worktree workflow will see <repo>/.claude/worktrees/<name>/ in real output, not .worktrees/. This makes the example misleading immediately after the document establishes the native path as primary.
✏️ Proposed update
-/workspaces/projects/CodeForge d2ba55e [main]
-/workspaces/projects/.worktrees/feature-a abc1234 [feature-a]
+/workspaces/projects/CodeForge d2ba55e [main]
+/workspaces/projects/CodeForge/.claude/worktrees/feature-a abc1234 [worktree-feature-a]📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| Output shows each worktree's path, HEAD commit, and branch: | |
| ```text | |
| /workspaces/projects/CodeForge d2ba55e [main] | |
| /workspaces/projects/.worktrees/feature-a abc1234 [feature-a] | |
| ``` | |
| Output shows each worktree's path, HEAD commit, and branch: | |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In
@.devcontainer/plugins/devs-marketplace/plugins/skill-engine/skills/worktree/SKILL.md
around lines 130 - 135, Update the example output for `git worktree list` in
SKILL.md to use the native-path-as-primary convention described earlier: replace
the legacy `.worktrees/feature-a` path with the native path format used by
EnterWorktree/--worktree (e.g., `<repo>/.claude/worktrees/<name>/feature-a`) and
keep the same HEAD/branch columns so the example matches the documented workflow
and symbols `EnterWorktree`, `--worktree`, and `git worktree list`.
New skill-engine skill covering EnterWorktree, --worktree CLI flag, .worktreeinclude setup, worktree management, and CodeForge integration. Updates system prompt <git_worktrees> to recommend native Claude Code convention alongside legacy .worktrees/ path.
…tent - Move system prompt changelog entry from Added to Changed section - Add Worktrees section to CLAUDE.md matching system prompt guidance - Add language tags to 5 fenced code blocks (MD040) across SKILL.md and manual-worktree-commands.md - Soften absolute merge conflict claim in parallel-workflow-patterns.md - Add EnterWorktree to SKILL.md allowed-tools - Add worktree to README.md skills list (21→22 entries) - Fix stale skill counts: 21→22 in features/index.md, getting-started/index.md, plugins/skill-engine.md (description + table); 34→35 in reference/architecture.md
4c2eec4 to
5f4c787
Compare
Summary
worktreeskill in the skill-engine plugin — full-lifecycle guide coveringEnterWorktreetool (primary),--worktreeCLI flag, manualgit worktreecommands,.worktreeincludesetup, worktree management, and CodeForge integration (Project Manager auto-detection, agent isolation)<git_worktrees>section now documents Claude Code native convention (<repo>/.claude/worktrees/) as recommended alongside legacy.worktrees/path, addsEnterWorktreeguidance and.worktreeincludedocumentationskill-suggester.pyupdated with worktree keyword entry (10 phrases, 3 terms)Test plan
/worktreein a Claude session — verify SKILL.md activatesEnterWorktreecreates worktree at native pathsetup-projects.shdetects worktrees in.worktrees/Summary by CodeRabbit
New Features
Documentation