chore(.gitignore): restrict build dir patterns to repo root - #745
Merged
Conversation
The unanchored `build-*/` pattern matched `.agents/skills/build-run/` at any depth, so files under that skill were silently ignored. The existing `!.claude/skills/build-run/` escape hatch went stale when skills moved from `.claude/` to `.agents/`. Anchor the build directory patterns to the repository root instead — every build directory this project creates lives at the root — which fixes the skill and removes the need for a negation rule. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QUwQxU8nuPrjvVpgag57FZ
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_cd789b74-64ce-4197-aa49-6f72a31e7a94) |
Contributor
Documentation previewThe documentation preview has been deployed for this pull request. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Updated
.gitignorepatterns for build directories to only match at the repository root, allowing build directories to exist in subdirectories (e.g.,.claude/skills/build-run/).Changes
build/→/build/to match only at repo rootbuild-*/→/build-*/to match only at repo root!.claude/skills/build-run/(no longer needed with root-only matching)Details
The leading slash in gitignore patterns anchors them to the repository root, preventing unintended matches in subdirectories. This allows skill directories like
.claude/skills/build-run/to maintain their own build artifacts without being ignored by the root-level gitignore rules.https://claude.ai/code/session_01QUwQxU8nuPrjvVpgag57FZ
Note
Low Risk
Git ignore-only change with no runtime or security impact; only affects which local build artifacts may be tracked.
Overview
Build ignore rules now apply only at the repository root:
build/andbuild-*/become/build/and/build-*/, with a comment noting repo-root scope.The
!.claude/skills/build-run/exception is removed because root-anchored patterns no longer ignore nestedbuild/folders under skills or other paths.Reviewed by Cursor Bugbot for commit 501cb1f. Configure here.