Add a version bump script - #39
Merged
Merged
Conversation
The framework version was hard-coded in three files and had to be edited by hand, so a release could easily ship with a stale value in one of them. - Add bump_version.sh, which updates the podspec, SUK.version, and the four MARKETING_VERSION entries in the framework project. - Verify the occurrence count in each file after substitution, because sed exits successfully even when no pattern matches. - Reject a malformed version and leave the sample apps, which have their own versions, untouched. - Expose it as the version:bump npm script and document the procedure in AGENTS.md. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
Summary
bump_version.sh, which updates the framework version in the podspec,SUK.version, and the fourMARKETING_VERSIONentries of the framework projectversion:bumpnpm script and document the procedure inAGENTS.mdMotivation
The version was hard-coded in three files and edited by hand for each release, so a release could ship with a stale value in one of them.
sedalso exits successfully when no pattern matches, so the script counts the occurrences it expects (1 / 1 / 4) and fails instead of reporting a bump it did not perform.Validation
./bump_version.sh 1.6.0updated all three files, then the working tree was restored to 1.5.0./bump_version.sh 1.6and an invocation with no argument both exited with status 1Notes
Regenerating the XCFramework and tagging remain manual. Those steps are better folded into #31, which makes XCFramework generation fail fast and reproducible.