-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Release script: Set draft status, and only remove after uploading asset #27713
Conversation
Size Change: 0 B Total Size: 1.28 MB ℹ️ View Unchanged
|
@@ -448,6 +456,19 @@ async function runGithubReleaseStep( | |||
log( '>> The plugin ZIP has been successfully uploaded.' ); | |||
} ); | |||
|
|||
// Remove draft status from the Github release | |||
await runStep( 'Publishing the Github release', abortMessage, async () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the new step necessary? I mean not just put this logic inside the previous step. (it's all related)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was considering that, but since release (now draft) creation and asset upload are separate, it seemed like removing the draft status should also be separate, since it's semantically not part of the asset upload step. (I don't feel strongly about this.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't test, but this seems like a good move.
Description
In the release script, rather than creating a GH release, and then attaching the plugin zip release asset, this PR creates a release draft first, attaches the plugin zip, and only then removes the draft state.
This is a prerequisite for GH action-based automation such as #27591.
Spun off from #27591 to allow for more isolated review and testing.
How has this been tested?
gutenberg
repo (if you haven't already), and make sure it's up-to-date.bin/plugin/config.js
(e.g. mine isockham
). This is important, as you don't want to accidentally create a release in the official repo!./bin/plugin/cli.js stable
and follow through the steps.Here's an example: https://github.com/ockham/gutenberg/releases/tag/v9.5.2
Types of changes
Release tooling.