Skip to content

Commit 03595aa

Browse files
Restructure release skill into ordered phases with verification gates (#5500)
- Group the 12 steps into 5 phases (Prep, GitHub PRs, ADO mirror, Signed pipelines, Publish) so the dependency chain is explicit - Verify the release commit landed (`git log -1 --format=%s`) before pushing to ADO, and wait for ADO PR `status=completed` before queuing pipelines -- phase 4 builds against `refs/heads/main` and would silently produce the wrong version if either gate were skipped - Split phase 4 into separate steps for PSES and vscode-powershell so the agent can notify me when each pipeline hits its manual approval stage - Drop the old "publishing the tag triggers marketplace" line: the vscode-powershell pipeline pushes to marketplace directly after approval, only the GitHub drafts need a manual publish - Use `gh release edit <tag> --repo <owner>/<repo> --generate-notes` to populate draft release bodies - Reference `release infrastructure` and `release maintainers` memory entries so private contacts stay out of the repo - Drop redundant rationale where the command itself already encodes the fix Drafted by Copilot (Claude Opus 4.7).
1 parent d292a37 commit 03595aa

1 file changed

Lines changed: 85 additions & 11 deletions

File tree

.github/skills/release/SKILL.md

Lines changed: 85 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,93 @@ description: >
77

88
# Release Process
99

10-
Read [docs/development.md](../../../docs/development.md) "Creating a Release" and "Versioning" sections first.
10+
Read [docs/development.md](../../../docs/development.md) "Creating a Release" and "Versioning"
11+
first — this skill only adds the agent-specific deltas.
1112

12-
## Agent-Actionable Steps (1–2)
13+
Memory entries this skill depends on (load before starting):
1314

14-
1. Use `./tools/updateVersion.ps1 -Version "<version>" -Changes "<summary>"` in both repos
15-
(PSES first, then vscode-powershell). The script validates even/odd rules, updates
16-
`package.json` version, prepends a changelog entry (auto-including the PSES version from
17-
`../PowerShellEditorServices`), and creates a commit.
18-
2. Push to an ephemeral `release` branch and open a PR to `main` on GitHub.
15+
- **`release infrastructure`** — ADO org, project, and pipeline IDs.
16+
- **`release maintainers`** — the GitHub PR reviewer and the ADO release approver (two
17+
different people).
1918

20-
## Manual Steps (3–4)
19+
PSES leads the extension at every step: its module is embedded in the signed extension
20+
build, so its release must land before the corresponding vscode-powershell action.
2121

22-
These require Azure DevOps access and cannot be performed by an agent:
22+
## Phase 1 — Prep
2323

24-
3. After merge, push `main` to the Azure DevOps remote (`ado HEAD:upstream`) to trigger signing pipelines.
25-
4. Download and test assets from draft GitHub Releases, then publish.
24+
1. **Sync `main`** in both `../PowerShellEditorServices` and `vscode-powershell`:
25+
`git checkout main && git pull --ff-only origin main`.
26+
2. **Propose version + summary.** In each repo run
27+
`git log --oneline $(git describe --tags --abbrev=0)..HEAD`, summarize user-visible
28+
changes, apply the rules from docs/development.md "Versioning", and confirm both
29+
versions and one-line summaries with the user before continuing.
30+
31+
## Phase 2 — GitHub release PRs
32+
33+
3. **Run `updateVersion.ps1`** in PSES first, then vscode-powershell:
34+
35+
```sh
36+
git checkout -B release
37+
pwsh -NoProfile -c '$env:GIT_EDITOR="true"; ./tools/updateVersion.ps1 -Version "<version>" -Changes "<summary>"'
38+
```
39+
40+
4. **Push and open PRs.** `git push origin release`, then open a PR to `main` via the
41+
GitHub MCP `create_pull_request` tool. Title is the commit subject
42+
(`v<version>: <summary>`). DM the GitHub PR reviewer on Teams with both PR links.
43+
5. **Enable auto-squash-merge** on both PRs:
44+
`gh pr merge --repo <owner>/<repo> <number> --squash --auto`.
45+
6. **Wait for both PRs to merge** (`gh pr view ... --json state,statusCheckRollup`).
46+
Don't busy-loop — check, report, pause if it'll be a while.
47+
48+
## Phase 3 — Mirror to ADO
49+
50+
7. **Sync `main` and push to ADO `upstream`** in both repos (PSES first). The verify
51+
step must print the release commit subject (`v<version>: <summary>`); if it doesn't,
52+
the PR hasn't merged yet — stop and wait.
53+
54+
```sh
55+
git checkout main && git pull --ff-only origin main
56+
git log -1 --format=%s
57+
git push ado HEAD:upstream
58+
```
59+
60+
8. **Open `upstream → main` PRs in ADO** with auto-complete enabled. The current `ado`
61+
MCP server doesn't reach our org, so use `az` (org/project from memory). Title is
62+
always `Integrate upstream changes`. Use **merge commit** (preserves GitHub history)
63+
and keep the `upstream` branch (re-pushed every release):
64+
65+
```sh
66+
az repos pr create --org <org> --project <project> --repository <repo> \
67+
--source-branch upstream --target-branch main \
68+
--title "Integrate upstream changes" --description "Integrate v<version> from GitHub upstream."
69+
az repos pr update --org <org> --id <pr-id> \
70+
--auto-complete true --squash false --delete-source-branch false
71+
```
72+
73+
DM the ADO release approver on Teams with both ADO PR links.
74+
75+
9. **Wait for both ADO PRs to complete**
76+
(`az repos pr show --org <org> --id <pr-id> --query status` returns `completed`).
77+
Auto-complete merges them once policy checks pass; phase 4 builds against
78+
`refs/heads/main` and will produce the wrong version if main hasn't been updated yet.
79+
80+
## Phase 4 — Signed pipelines
81+
82+
Each pipeline pauses at a manual approval stage before publishing. Notify the user
83+
when each one reaches it. Use a detached watcher (`az pipelines runs show --id
84+
<run-id>`) so polling survives across turns.
85+
86+
10. **Queue the PSES pipeline** on `refs/heads/main` with template parameters
87+
`Release=True OfficialBuild=True`. Notify the user when it reaches the approval
88+
stage, then wait for `result == succeeded`. On success the pipeline creates a
89+
draft GitHub Release in PSES.
90+
11. **Queue the vscode-powershell pipeline** the same way. Notify the user at its
91+
approval stage. On success the pipeline creates a draft GitHub Release in
92+
vscode-powershell _and_ publishes the extension to the VS Code marketplace.
93+
94+
## Phase 5 — Publish GitHub releases (manual)
95+
96+
12. For each draft GitHub Release (PSES and vscode-powershell), populate the body via
97+
`gh release edit v<version> --repo <owner>/<repo> --generate-notes`. Send the user
98+
links to both drafts for review; they publish them manually. The marketplace push
99+
already happened in step 11.

0 commit comments

Comments
 (0)