@orderful/droid 0.43.0 → 0.44.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/tools/release/skills/release/SKILL.md +3 -2
- package/dist/tools/release/skills/release/references/templates.md +21 -0
- package/dist/tools/release/skills/release/references/workflows.md +40 -3
- package/package.json +1 -1
- package/src/tools/release/skills/release/SKILL.md +3 -2
- package/src/tools/release/skills/release/references/templates.md +21 -0
- package/src/tools/release/skills/release/references/workflows.md +40 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @orderful/droid
|
|
2
2
|
|
|
3
|
+
## 0.44.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#259](https://github.com/Orderful/droid/pull/259) [`f64bab2`](https://github.com/Orderful/droid/commit/f64bab250e25bb57ad9c1c2ac50246455a18eb42) Thanks [@frytyler](https://github.com/frytyler)! - Add /release merge command to merge release PRs when all checks pass and notify Slack. Fix release notes generation to compare branches instead of listing all historically merged PRs.
|
|
8
|
+
|
|
3
9
|
## 0.43.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: release
|
|
3
|
-
description: "Release ceremony automation for dev-to-master releases. Use when starting a release, checking release status, or completing a release. User prompts like 'start a release', 'release status', 'release complete'."
|
|
4
|
-
argument-hint: "[start [repo] | status | complete [repo]]"
|
|
3
|
+
description: "Release ceremony automation for dev-to-master releases. Use when starting a release, merging a release, checking release status, or completing a release. User prompts like 'start a release', 'merge the release', 'release status', 'release complete'."
|
|
4
|
+
argument-hint: "[start [repo] | merge [repo] | status | complete [repo]]"
|
|
5
5
|
allowed-tools: [Read, Write, Glob, Grep, Bash, Edit]
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -48,6 +48,7 @@ If no repos have `release_branch` set, tell user:
|
|
|
48
48
|
| Command | Action |
|
|
49
49
|
|---------|--------|
|
|
50
50
|
| `/release start [repo]` | Create release PR + notify Slack |
|
|
51
|
+
| `/release merge [repo]` | Merge release PR (only if checks pass) + notify Slack |
|
|
51
52
|
| `/release status` | Check open release PRs + CI state |
|
|
52
53
|
| `/release complete [repo]` | Post completion to Slack |
|
|
53
54
|
|
|
@@ -24,6 +24,19 @@ Risk emojis:
|
|
|
24
24
|
- Low Risk: `:large_green_circle:`
|
|
25
25
|
- High Risk: `:warning:`
|
|
26
26
|
|
|
27
|
+
### Release Merged
|
|
28
|
+
|
|
29
|
+
```
|
|
30
|
+
:merged-pr: *Release merged — {repo_name}*
|
|
31
|
+
|
|
32
|
+
*PR:* <{pr_url}|#{pr_number}>
|
|
33
|
+
*Branch:* `{release_branch}` → `{production_branch}`
|
|
34
|
+
|
|
35
|
+
Monitoring deployment :eyes:
|
|
36
|
+
|
|
37
|
+
Posted with :droid:
|
|
38
|
+
```
|
|
39
|
+
|
|
27
40
|
### Release Complete
|
|
28
41
|
|
|
29
42
|
```
|
|
@@ -76,6 +89,14 @@ Release started — {repo_name}
|
|
|
76
89
|
Branch: {release_branch} -> {production_branch}
|
|
77
90
|
```
|
|
78
91
|
|
|
92
|
+
### Release Merged (terminal)
|
|
93
|
+
```
|
|
94
|
+
Release merged — {repo_name}
|
|
95
|
+
PR: {pr_url}
|
|
96
|
+
Branch: {release_branch} -> {production_branch}
|
|
97
|
+
Monitoring deployment...
|
|
98
|
+
```
|
|
99
|
+
|
|
79
100
|
### Release Complete (terminal)
|
|
80
101
|
```
|
|
81
102
|
Release complete — {repo_name}
|
|
@@ -39,11 +39,14 @@ Create a release PR and notify Slack.
|
|
|
39
39
|
```
|
|
40
40
|
If one exists, show it and ask: "A release PR already exists. Open it instead?"
|
|
41
41
|
|
|
42
|
-
3. **Generate release notes** —
|
|
42
|
+
3. **Generate release notes** — compare branches to find PRs included in this release:
|
|
43
43
|
```bash
|
|
44
|
-
|
|
44
|
+
# Get commits in release_branch that aren't in production_branch
|
|
45
|
+
gh api repos/{owner}/{repo}/compare/{production_branch}...{release_branch} --jq '.commits[].commit.message'
|
|
45
46
|
```
|
|
46
|
-
|
|
47
|
+
Extract PR numbers from commit messages (e.g. `(#1234)`) and format as a bulleted list for the PR body.
|
|
48
|
+
|
|
49
|
+
**Do NOT use** `gh pr list --base {release_branch} --state merged` — that returns ALL historically merged PRs, not just the ones since the last release.
|
|
47
50
|
|
|
48
51
|
4. **Ask risk level** — use AskUserQuestion:
|
|
49
52
|
- Low Risk (routine release, no breaking changes)
|
|
@@ -75,6 +78,40 @@ Create a release PR and notify Slack.
|
|
|
75
78
|
|
|
76
79
|
---
|
|
77
80
|
|
|
81
|
+
## `/release merge [repo]`
|
|
82
|
+
|
|
83
|
+
Merge the release PR if all checks are green, then notify Slack.
|
|
84
|
+
|
|
85
|
+
### Steps
|
|
86
|
+
|
|
87
|
+
1. **Detect repo** — match cwd or ask user
|
|
88
|
+
|
|
89
|
+
2. **Find the open release PR:**
|
|
90
|
+
```bash
|
|
91
|
+
gh pr list --search "[RELEASE]" --state open --base {production_branch} --head {release_branch} --json number,title,url,statusCheckRollup --repo {owner}/{repo}
|
|
92
|
+
```
|
|
93
|
+
If no open release PR found, error: "No open release PR found. Run `/release start` first."
|
|
94
|
+
|
|
95
|
+
3. **Check all status checks:**
|
|
96
|
+
Parse `statusCheckRollup` from the PR data. Every check must have `conclusion: "SUCCESS"` or `state: "SUCCESS"`.
|
|
97
|
+
|
|
98
|
+
If any checks are pending: "CI checks are still running on PR #{number}. Wait for them to finish."
|
|
99
|
+
If any checks are failing: "CI checks are failing on PR #{number}. Fix them before merging." Show the failing checks.
|
|
100
|
+
|
|
101
|
+
4. **Confirm with user** — use AskUserQuestion:
|
|
102
|
+
"All checks are green on PR #{number}. Merge `{release_branch}` → `{production_branch}`?"
|
|
103
|
+
|
|
104
|
+
5. **Merge the PR:**
|
|
105
|
+
```bash
|
|
106
|
+
gh pr merge {pr_number} --merge --repo {owner}/{repo}
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
6. **Post to Slack** — release merged notification (see `templates.md`).
|
|
110
|
+
|
|
111
|
+
7. **Confirm to user** — show merge confirmation and Slack post confirmation.
|
|
112
|
+
|
|
113
|
+
---
|
|
114
|
+
|
|
78
115
|
## `/release status`
|
|
79
116
|
|
|
80
117
|
Check release status across all configured release repos.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: release
|
|
3
|
-
description: "Release ceremony automation for dev-to-master releases. Use when starting a release, checking release status, or completing a release. User prompts like 'start a release', 'release status', 'release complete'."
|
|
4
|
-
argument-hint: "[start [repo] | status | complete [repo]]"
|
|
3
|
+
description: "Release ceremony automation for dev-to-master releases. Use when starting a release, merging a release, checking release status, or completing a release. User prompts like 'start a release', 'merge the release', 'release status', 'release complete'."
|
|
4
|
+
argument-hint: "[start [repo] | merge [repo] | status | complete [repo]]"
|
|
5
5
|
allowed-tools: [Read, Write, Glob, Grep, Bash, Edit]
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -48,6 +48,7 @@ If no repos have `release_branch` set, tell user:
|
|
|
48
48
|
| Command | Action |
|
|
49
49
|
|---------|--------|
|
|
50
50
|
| `/release start [repo]` | Create release PR + notify Slack |
|
|
51
|
+
| `/release merge [repo]` | Merge release PR (only if checks pass) + notify Slack |
|
|
51
52
|
| `/release status` | Check open release PRs + CI state |
|
|
52
53
|
| `/release complete [repo]` | Post completion to Slack |
|
|
53
54
|
|
|
@@ -24,6 +24,19 @@ Risk emojis:
|
|
|
24
24
|
- Low Risk: `:large_green_circle:`
|
|
25
25
|
- High Risk: `:warning:`
|
|
26
26
|
|
|
27
|
+
### Release Merged
|
|
28
|
+
|
|
29
|
+
```
|
|
30
|
+
:merged-pr: *Release merged — {repo_name}*
|
|
31
|
+
|
|
32
|
+
*PR:* <{pr_url}|#{pr_number}>
|
|
33
|
+
*Branch:* `{release_branch}` → `{production_branch}`
|
|
34
|
+
|
|
35
|
+
Monitoring deployment :eyes:
|
|
36
|
+
|
|
37
|
+
Posted with :droid:
|
|
38
|
+
```
|
|
39
|
+
|
|
27
40
|
### Release Complete
|
|
28
41
|
|
|
29
42
|
```
|
|
@@ -76,6 +89,14 @@ Release started — {repo_name}
|
|
|
76
89
|
Branch: {release_branch} -> {production_branch}
|
|
77
90
|
```
|
|
78
91
|
|
|
92
|
+
### Release Merged (terminal)
|
|
93
|
+
```
|
|
94
|
+
Release merged — {repo_name}
|
|
95
|
+
PR: {pr_url}
|
|
96
|
+
Branch: {release_branch} -> {production_branch}
|
|
97
|
+
Monitoring deployment...
|
|
98
|
+
```
|
|
99
|
+
|
|
79
100
|
### Release Complete (terminal)
|
|
80
101
|
```
|
|
81
102
|
Release complete — {repo_name}
|
|
@@ -39,11 +39,14 @@ Create a release PR and notify Slack.
|
|
|
39
39
|
```
|
|
40
40
|
If one exists, show it and ask: "A release PR already exists. Open it instead?"
|
|
41
41
|
|
|
42
|
-
3. **Generate release notes** —
|
|
42
|
+
3. **Generate release notes** — compare branches to find PRs included in this release:
|
|
43
43
|
```bash
|
|
44
|
-
|
|
44
|
+
# Get commits in release_branch that aren't in production_branch
|
|
45
|
+
gh api repos/{owner}/{repo}/compare/{production_branch}...{release_branch} --jq '.commits[].commit.message'
|
|
45
46
|
```
|
|
46
|
-
|
|
47
|
+
Extract PR numbers from commit messages (e.g. `(#1234)`) and format as a bulleted list for the PR body.
|
|
48
|
+
|
|
49
|
+
**Do NOT use** `gh pr list --base {release_branch} --state merged` — that returns ALL historically merged PRs, not just the ones since the last release.
|
|
47
50
|
|
|
48
51
|
4. **Ask risk level** — use AskUserQuestion:
|
|
49
52
|
- Low Risk (routine release, no breaking changes)
|
|
@@ -75,6 +78,40 @@ Create a release PR and notify Slack.
|
|
|
75
78
|
|
|
76
79
|
---
|
|
77
80
|
|
|
81
|
+
## `/release merge [repo]`
|
|
82
|
+
|
|
83
|
+
Merge the release PR if all checks are green, then notify Slack.
|
|
84
|
+
|
|
85
|
+
### Steps
|
|
86
|
+
|
|
87
|
+
1. **Detect repo** — match cwd or ask user
|
|
88
|
+
|
|
89
|
+
2. **Find the open release PR:**
|
|
90
|
+
```bash
|
|
91
|
+
gh pr list --search "[RELEASE]" --state open --base {production_branch} --head {release_branch} --json number,title,url,statusCheckRollup --repo {owner}/{repo}
|
|
92
|
+
```
|
|
93
|
+
If no open release PR found, error: "No open release PR found. Run `/release start` first."
|
|
94
|
+
|
|
95
|
+
3. **Check all status checks:**
|
|
96
|
+
Parse `statusCheckRollup` from the PR data. Every check must have `conclusion: "SUCCESS"` or `state: "SUCCESS"`.
|
|
97
|
+
|
|
98
|
+
If any checks are pending: "CI checks are still running on PR #{number}. Wait for them to finish."
|
|
99
|
+
If any checks are failing: "CI checks are failing on PR #{number}. Fix them before merging." Show the failing checks.
|
|
100
|
+
|
|
101
|
+
4. **Confirm with user** — use AskUserQuestion:
|
|
102
|
+
"All checks are green on PR #{number}. Merge `{release_branch}` → `{production_branch}`?"
|
|
103
|
+
|
|
104
|
+
5. **Merge the PR:**
|
|
105
|
+
```bash
|
|
106
|
+
gh pr merge {pr_number} --merge --repo {owner}/{repo}
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
6. **Post to Slack** — release merged notification (see `templates.md`).
|
|
110
|
+
|
|
111
|
+
7. **Confirm to user** — show merge confirmation and Slack post confirmation.
|
|
112
|
+
|
|
113
|
+
---
|
|
114
|
+
|
|
78
115
|
## `/release status`
|
|
79
116
|
|
|
80
117
|
Check release status across all configured release repos.
|