Skip to content

chore(.gitignore): restrict build dir patterns to repo root - #745

Merged
stackia merged 1 commit into
mainfrom
claude/build-run-skill-gitignore-bwiic5
Sep 3, 2026
Merged

chore(.gitignore): restrict build dir patterns to repo root#745
stackia merged 1 commit into
mainfrom
claude/build-run-skill-gitignore-bwiic5

Conversation

@stackia

@stackia stackia commented Sep 3, 2026

Copy link
Copy Markdown
Owner

Summary

Updated .gitignore patterns for build directories to only match at the repository root, allowing build directories to exist in subdirectories (e.g., .claude/skills/build-run/).

Changes

  • Changed build//build/ to match only at repo root
  • Changed build-*//build-*/ to match only at repo root
  • Removed the negation pattern !.claude/skills/build-run/ (no longer needed with root-only matching)
  • Updated comment to clarify scope: "Build directories (repo root only)"

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/ and build-*/ 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 nested build/ folders under skills or other paths.

Reviewed by Cursor Bugbot for commit 501cb1f. Configure here.

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
@cursor

cursor Bot commented Sep 3, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot 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)

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Documentation preview

The documentation preview has been deployed for this pull request.

@stackia
stackia merged commit 86cd640 into main Sep 3, 2026
12 checks passed
@stackia
stackia deleted the claude/build-run-skill-gitignore-bwiic5 branch September 3, 2026 23:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants