Repository navigation
ci: skip betas of pushes that change only docs, CI or tests - #309
Merged
Merged
Conversation
Once a fix or feature waits for a stable release, every push to main published a beta, even one that ships the same app as the beta before it. 6 of the 77 betas so far were like that, the betas of #297 and #308 among them: beta users got an update prompt for the same app, and CI built, signed and notarized it. scripts/unchanged-app.sh tells when HEAD ships the same app as the newest release: every commit since is docs, ci or test, and none touches Sources, Resources, Package.swift, Package.resolved or scripts. The beta job then publishes nothing, and the stable job accepts the beta before such commits, so a stable release still ships an app beta users have run.
The whole suite runs in parallel, and on CI one git command in the new release history tests took longer than the 10-second default, failing two of them. Their commands now get 60 seconds, and only the script's exit status 1 counts as a changed app, so a timeout can't pass for one.
|
🎉 This PR is included in version 0.8.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
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.
Problem
Once a fix or feature is waiting for a stable release, every push to
mainpublishes a beta, even when the app is the same as in the beta before it. 6 of the 77 betas so far were like that, includingv0.8.0-beta.…380(#297) andv0.8.0-beta.…382(#308). Beta users get an update prompt for the same app, and CI builds, signs and notarizes it for nothing.Changes
scripts/unchanged-app.shprints the newest release beforeHEADwhenHEADships the same app. That means every commit since then isdocs:,ci:ortest:, and none of them touchesSources,Resources,Package.swift,Package.resolvedorscripts. Merge commits are left out of the type check but not the file check. The file check is needed because adocs:commit can still change the app: the triage playbook is built intoSources/StableBar/Triage.swift.mainmoved on still gets its beta from the push after it.refactor:,style:,build:andchore:still publish betas, because they can change the built app.Testing
swift test --filter unchangedApp: 5 tests (11 cases) on scratch Git histories. They cover docs, scoped CI and test commits after a beta, including through a merge commit and with theappcasttag nearer toHEAD; a beta on the newest commit; commits that touchSources,Resources,scriptsorPackage.resolved;fix:,refactor:anddocs!:types; a merge commit that changesSources; and a history with no release.mainafter merging is itself aci:change toscripts, so it still publishes a beta. A docs merge after that should log "No beta: the commits since … change only docs, CI or tests."Merging
Two commits: the change, and a
test:commit that gives the new tests 60 seconds per git command, since one took longer than the 10-second default on CI. Either a merge commit or a squash works; neither commit changes the app.Claude Opus 5.5 via Claude Code