fix: update .gitignore files to include additional ignored patterns - #1367
Conversation
|
You do not have enough credits to review this pull request. Please purchase more credits to continue. |
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
Disabled knowledge base sources:
📝 WalkthroughSummary by CodeRabbit
WalkthroughThis pull request expands ignore patterns across multiple configuration files to exclude directories and caches from various AI development tools: Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Poem
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Mesa DescriptionTL;DRUpdated What changed?Modified various Description generated by Mesa. Update settings |
There was a problem hiding this comment.
Code Review
This pull request updates the repository and global gitignore files to include various AI-related directories and the Jujutsu (.jj) directory, while also updating the worktrunk configuration to exclude .paperclip/. Feedback was provided regarding a bug where the modified .claude ignore pattern prevents the tracking of settings.json, as well as suggestions to resolve redundant patterns and avoid global ignores for directories containing shared configurations.
| # AI | ||
| .claude/* | ||
| .aider.tags.cache.v4 | ||
| .claude |
There was a problem hiding this comment.
Changing .claude/* to .claude will cause Git to ignore the entire directory. When a directory is ignored, Git does not process negation patterns (like !) for files inside that directory. To keep settings.json tracked while ignoring other files in .claude, you must use the .claude/* pattern.
.claude/*
| @@ -1,7 +1,14 @@ | |||
| # AI | |||
| .claude/* | |||
| .aider.tags.cache.v4 | |||
There was a problem hiding this comment.
The pattern .aider.tags.cache.v4 is redundant because .aider* is already defined on line 78 of this file. Additionally, using a version-specific pattern like v4 is brittle; if you wish to keep this entry at the top for organization, consider a version-agnostic pattern like .aider.tags.cache.* to match the style used in the global gitignore.
| @@ -1,7 +1,11 @@ | |||
| # AI | |||
| .aider.tags.cache.*/ | |||
| .claude/ | |||
There was a problem hiding this comment.
Adding .claude/ to the global gitignore can be problematic for repositories that intend to track specific configuration files within that directory (such as settings.json in this repository). While repo-level negations can override global ignores, they require explicitly un-ignoring the directory first. It is generally safer to keep tool-specific ignores that might contain shared configuration at the repository level.
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Updates ignore configuration to cover additional AI/editor tooling artifacts and improves worktree copy behavior by excluding more generated directories.
Changes:
- Expand ignored patterns in the repo and global Git ignore configs (AI tool dirs/files + JJ
.jj). - Update Worktrunk’s
copy-ignoredstep to exclude.paperclip/.
Reviewed changes
Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| home-manager/programs/git/.gitignore.global | Adds additional AI tool directories to the global ignore list. |
| config/worktrunk/config.toml | Excludes .paperclip/ from the copy-ignored step. |
| .gitignore | Expands repo-level ignores for AI tools and adds .jj. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| @@ -1,7 +1,11 @@ | |||
| # AI | |||
| .aider.tags.cache.*/ | |||
| .claude/ | |||
There was a problem hiding this comment.
With .claude/ ignored globally, repositories that want to keep a whitelisted file like .claude/settings.json must also unignore the directory itself (e.g., !.claude/) in the repo ignore file; otherwise the nested unignore may not work. Given this PR also introduces a repo-level whitelist for .claude/settings.json, consider changing the global ignore to only ignore contents (e.g., .claude/*) or document/standardize the required !.claude/ + !.claude/settings.json pair in repo .gitignore.
| .claude/ | |
| .claude/* |
| @@ -1,7 +1,11 @@ | |||
| # AI | |||
| .aider.tags.cache.*/ | |||
There was a problem hiding this comment.
The global ignore uses a directory-only wildcard pattern (.aider.tags.cache.*/), while the repo .gitignore ignores a specific versioned entry (.aider.tags.cache.v4). This split is easy to drift and may miss future versions or file-vs-directory differences. Consider standardizing on a single pattern that covers all versions consistently across both files (e.g., a wildcard that matches versioned cache names regardless of whether they’re files or directories).
| .aider.tags.cache.*/ | |
| .aider.tags.cache.* |
Summary by cubic
Expand repo and global .gitignore to ignore common tool caches (e.g., .claude, .cursor, .paperclip, .serena, .aider tags) and JJ’s .jj directory to prevent accidental commits. Also update Worktrunk config to exclude .paperclip in the copy-ignored step.
Written for commit c71157d. Summary will update on new commits.