Skip to content

chore(ci): stop demanding a bump from PRs that ship nothing - #27

Merged
tkoehlerlg merged 1 commit into
mainfrom
chore/version-check-docs-only
Sep 25, 2026
Merged

tkoehlerlg merged 1 commit into
mainfrom
chore/version-check-docs-only

Conversation

@tkoehlerlg

Copy link
Copy Markdown
Contributor

Why

package.json says 0.7.2. npm's latest is 0.7.1. The difference between them is nothing an installer can observe.

files is ["dist"], so the tarball is the build output plus the three files npm always adds — package.json, README.md, LICENSE. PRs #25 and #26 changed ARCHITECTURE.md, CLAUDE.md and two files under docs/. None of that ships. But Version Check failed until the version moved, so it moved, and 0.7.2 became a release that cannot be worth publishing: its tarball differs from 0.7.1 only in the version string.

I wrote the check that did this, in #21. The comment in it — "Every merge into main is released, so every PR must carry the bump" — is the premise that is wrong. Not every merge changes what is released.

What changed

One step ahead of the others: what did this PR touch?

NOT_PUBLISHED='^(docs/|\.github/|\.claude/|tests/|ARCHITECTURE\.md|CLAUDE\.md|CONTRIBUTING\.md|CHANGELOG\.md|AGENTS\.md)'

If every changed file matches, the job says so and passes. If anything else changed — src/, package.json, README.md, LICENSE — the three original steps run exactly as before. The comparison logic is untouched; it is only now preceded by a question.

fetch-depth: 0 is added because the diff needs the base commit.

Verified

The classifier was run against real file lists rather than reasoned about:

Input Result
#25 + #26 without their bump (ARCHITECTURE.md, CLAUDE.md, docs/*) skip
#25 + #26 as merged (the above plus package.json) bump required
v0.7.0 → v0.7.1 (README.md, bun.lock, workflows, package.json) bump required
src/core/scheduler.ts + its test bump required
a test-only change skip
README.md alone bump required

The second row is worth reading twice: a docs PR that does carry a bump still takes the strict path, and passes on its own merits. Only a PR with no publishable change at all skips.

What this does not do

It does not publish 0.7.2 and it does not revert the version. package.json stays at 0.7.2, unpublished, and the next change that actually ships goes out under that number. Tags, npm and GitHub Releases stay consistent — 0.7.2 simply has not happened yet, which is the normal state of an unreleased bump rather than the drift this repo has had before.

🤖 Generated with Claude Code

`files` is ["dist"], so a PR touching only docs, tests or workflows leaves
the tarball byte-identical — and the check still failed until someone
bumped. That is where 0.7.2 came from: a version whose only difference
from 0.7.1 is the version string, which is why it was never published.

The check now asks what the PR changes before asking for a version.
Anything an installer receives — src, package.json, README, LICENSE —
still requires the bump.

Classification verified against real file lists: the 0.7.2 docs PR
without its bump, a src change, a tests-only change, a README change,
and the 0.7.1 workflow change.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@codecov

codecov Bot commented Sep 24, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@tkoehlerlg
tkoehlerlg merged commit 1ba9586 into main Sep 25, 2026
6 checks passed
@tkoehlerlg
tkoehlerlg deleted the chore/version-check-docs-only branch September 25, 2026 20:48
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.

1 participant