[DNM] Post-"ghost"-release hotfix workflow #8264
Draft
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.
Ticket here
Create hotfix from any release
This modifies the existing create hotfix workflow to accept parameters for
version
andapplication
. Specifying these values allows you to create a hotfix branch at the point of any previous releaseversion
is optional, and if unspecified defaults to "latest" - a special keyword that bypasses the tag finding process (see below), instead creating the hotfix branch frommain
just as the workflow did before this PRapplication
is mandatory and is implemented as achoice
dropdown with LLM and LLD as the only two optionsIf
version
is specified it is reformatted into a tag using the specifiedapplication
, e.g. version2.91.0
+LLD
will be reformatted into a the tag for the 2.91.0 release@ledgerhq/[email protected]
. This is then used to checkout the repo prior to the remaining hotfix steps.Edge case behaviour:
version
and submits it as empty: it falls back to a ref ofmain
(test run)version
is a non-existent version:git fetch
fails during the checkout action (test run).Enforce patch version bumps in hotfix
The PR also restricts version bumps to patches, by enforcing a check in the
prepare-hotfix
workflow. This is the counterpart to #8244 which disallows patch versioning on any branch that is not hotfix.Remove merge steps
The PR also removes workflow steps for merging the hotfix branch back into
main
anddevelop
. To confirm, the new process is:main
ordevelop
)