Keep hand-maintained skill files out of the format check - #264
Open
NathanTarbert wants to merge 1 commit into
Open
Keep hand-maintained skill files out of the format check#264NathanTarbert wants to merge 1 commit into
NathanTarbert wants to merge 1 commit into
Conversation
The format check added by #250 runs against the files a PR touches, which is the right shape -- but two kinds of file in this repo get worse when prettier formats them, and both are now failing PRs that have nothing wrong with them. .claude/skills/*.md are hand-maintained spec prose carrying wide reference tables. Prettier pads every cell out to the widest one, so a one-word edit rewrites the whole table and the real change disappears into the diff. On #238 that is 305 changed lines across two SKILL.md files. docs/community-signal/reddit-pulse-seen.json is operational dedup state, appended by the weekly-report routine rather than written by hand, and 2-space by construction. The repo's tabWidth is 4, so formatting it reindents all 412 lines -- and the next run rewrites it 2-space again, so the check would break again every week. Both patterns are anchored with a leading slash, for the reason the /templates/ entry above them records: unanchored, a gitignore-style pattern matches a directory of that name at any depth. Verified against the CI step's own command over #238's three changed files: fails before, passes after. Repo-wide `prettier --check .` is unchanged at 334 pre-existing warnings, and .claude/settings.json stays covered -- the only tracked files this exempts are the 13 markdown skill definitions.
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.
The format check from #250 skips two kinds of file that get worse when prettier touches them. Both are currently failing PRs that have nothing wrong with them — #238 is red on this and only this.
Why not just format the files
.claude/skills/*.mdare hand-maintained spec prose, and several carry wide reference tables. Prettier pads every cell out to the widest one:becomes
So a one-word edit rewrites the whole table and the actual change disappears into the diff. On #238 that is 305 changed lines across two
SKILL.mdfiles, in a PR whose point is a spec correction.docs/community-signal/reddit-pulse-seen.jsonis operational dedup state — Reddit post IDs appended by the weekly-report routine, not written by hand. It is 2-space by construction and the repo'stabWidthis 4, so formatting it reindents all 412 lines. The next run writes it 2-space again, so the check would break again every week. CLAUDE.md names this file the one allowed data artifact in the repo, which is the other reason not to have prettier own its shape.Scope
Both patterns are anchored with a leading slash, for the reason the
/templates/entry above them already records: unanchored, a gitignore-style pattern matches a directory of that name at any depth, which is how 11 tracked source files got silently exempted last time.The only tracked files this exempts are the 13 markdown skill definitions. There is no
.ts/.js/.jsonunder.claude/skills/, and.claude/settings.jsonstays covered.Verification
Ran the CI step's own command over #238's three changed files — fails before, passes after:
Repo-wide
prettier --check .is unchanged at 334 pre-existing warnings, so nothing that was being checked has stopped being checked.Note for #238
This is split out rather than folded into #238 because it fixes a repo-wide gap rather than anything about that PR. #238 needs a rebase onto this to go green — and it still has changes requested on the content, so this only clears CI.