[CI] add check for packages needing version increment #3631
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.
Description
ensure_version_bump.shtakes a Git tag (defaulting to most recent) and a path (defaulting to cwd) and complains about any R package under that path that both (1) has any changes since the tag; and (2) has not changed its package version.CI/checkGHA workflowMotivation and Context
Way back when, all PEcAn packages shared a version and we incremented it each time we tagged a PEcAn release.
Then we started versioning each package individually, but with a mass version bump both before (setting intended release version following semver rules) and after (appending '.9000' to each package to indicate an unreleased development version) tagging each release. This meant it was not possible for a package to keep the same version across two PEcAn releases, even if nothing had changed in the package. It also meant there was no clear way to release the same version of a package both inside and outside of a PEcAn system release (e.g. if we started submitting packages to CRAN).
Starting with PEcAn 1.9.0, we decided to stop mass-adding the .9000 suffix and instead expect a version bump in the first PR that touches each package after release. Then if we are not updating a package there is nothing further to do to it at release time, extraneous version increments are eliminated, and each package can be set to its next release version whenever we finish work on it; no need to wait for a release branch.
The obvious drawback of expecting version bumps to be done during routine PRs rather than at release time is that it's easy to forget to do them -- see as evidence the 18 packages I'm updating after the fact here! Hence this PR to make the robots remember for us.
Review Time Estimate
Types of changes
Checklist: