File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -42,15 +42,23 @@ gh run watch <run-id> --interval 30
4242
4343The ` update-release-draft ` job at the end of CI creates or updates the draft release. If any job on ` main ` fails, stop and report to the user.
4444
45- ## Step 4: Find the draft release
45+ ## Step 4: Find the draft release and check the version bump
4646
47- List recent releases to find the draft that was just updated :
47+ List recent releases to find the draft and the last published release :
4848
4949``` bash
5050gh release list --limit 5 --json tagName,name,isDraft
5151```
5252
53- Identify the draft release (isDraft: true). Confirm its name with the user before publishing.
53+ Identify the draft release (isDraft: true) and the most recent non-draft release. Parse their
54+ semantic version numbers (e.g. ` v1.2.3 ` ) and determine whether the bump from the previous release
55+ to the draft is a ** patch** (only the third number changed), ** minor** (second number changed), or
56+ ** major** (first number changed).
57+
58+ - If the bump is ** minor or major** , stop and explicitly ask the user: "The draft release is
59+ ` <draft-name> ` , which is a [ minor/major] bump from ` <previous-name> ` . Is that correct?" Do not
60+ proceed until the user confirms.
61+ - If the bump is ** patch** , proceed without asking.
5462
5563## Step 5: Publish the draft release
5664
You can’t perform that action at this time.
0 commit comments