Repository navigation
docs(optimize): remove references to .claudeignore (#61) - #68
Merged
AgentSeal merged 2 commits intoApr 17, 2026
Merged
Conversation
Claude Code does not document or implement a .claudeignore feature. The junk-reads detector's fix is now a CLAUDE.md instruction asking Claude to avoid generated/dependency directories. The separate detectMissingClaudeignore finding and its tests are removed; checking for the presence of a non-existent file has no signal. Closes getagentseal#61.
Prevents agent-scratchpad files under .claude/ from being accidentally staged by tooling. Matches the existing pattern for docs/superpowers/.
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.
Closes #61.
Background
As reported by @cpennington, the optimizer references
.claudeignoreas if it were a Claude Code feature. It is not — Claude Code has no documented or undocumented.claudeignoremechanism as of 2026-04-17.Changes
detectJunkReadsfinding stays (it's a legitimate signal — Claude reading intonode_modules,.git, etc. is real waste). The fix action changes from "create a.claudeignorefile" to apaste-style suggestion asking the user to append a short instruction to theirCLAUDE.mdtelling Claude to avoid those directories. That mechanism actually exists and works.detectMissingClaudeignorefinding is removed entirely. The whole detector's premise was "you havenode_modulesbut no.claudeignore" — checking for the presence of a non-existent file is not a signal. Removed the function, its call-site, its four fs-tests, and two unit tests.ESTIMATED_READS_PER_MISSING_IGNORE,MISSING_IGNORE_HIGH_THRESHOLD,MISSING_IGNORE_PATHS_PREVIEW,JUNK_DIRS_IGNORE_PREVIEW) removed along with their single caller.Test Coverage
npx vitest run— 192/192 pass (was 198 before; six tests removed along with the finding they covered).One existing test was updated:
builds .claudeignore content from detected + common extras→suggests CLAUDE.md advice listing detected and common junk dirs, now asserts against the newpastefix shape.Also in this PR
Small chore:
.claude/added to.gitignore(second commit). Agent scratchpads land there when working in this tree and should not be staged. Matches the existing pattern fordocs/superpowers/.Compatibility