Repository navigation
Add release skill
#783
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
Draft
adamkudrna
wants to merge
2
commits into
master
Choose a base branch
from
maintenance/release-skill
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+109
−0
Draft
Add release skill
#783
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| # Release Skill | ||
|
|
||
| Run `/release` to prepare a new version of React UI. It chooses the version, | ||
| bumps it on a `release/vX.Y.Z` branch, runs the checks and gives you the expected | ||
| changelog. | ||
|
|
||
| You still update the GitHub release draft and merge the PR, because merging is | ||
| what publishes the release. The skill can then confirm the release went out. | ||
|
|
||
| See [SKILL.md](./SKILL.md) for the steps and | ||
| [Releasing](../../../src/docs/contribute/releasing.md) for the process itself. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,98 @@ | ||
| --- | ||
| description: Prepare a React UI release by choosing the version, bumping it on a release branch, running checks and preparing the changelog. Use whenever the user asks to prepare, cut or start a release, or to bump the version for one. Stops before merging, because merging publishes. | ||
| --- | ||
|
|
||
| # Release | ||
|
|
||
| Follows [Releasing](../../../src/docs/contribute/releasing.md). Merging the | ||
| release PR publishes the GitHub release and npm package and deploys the docs, | ||
| so never merge it. Commit, push or open the PR only when the user asks. | ||
|
|
||
| ## 1. Choose the version | ||
|
|
||
| 1. Start from an up-to-date `master` with no unrelated staged changes. | ||
| 2. List merged PRs into `master` since the last tag, with their labels. Use the | ||
| GitHub MCP tools, as `gh` may not be installed. | ||
| 3. Pick the version. While on `0.x`: | ||
|
|
||
| | Merged PR labels | Bump | Example | | ||
| |------------------------|-------|--------------------| | ||
| | `BC` or `feature` | minor | `0.63.1` → `0.64.0` | | ||
| | Anything else | patch | `0.64.0` → `0.64.1` | | ||
|
|
||
| ## 2. Bump | ||
|
|
||
| 1. Create the `release/vX.Y.Z` branch. | ||
| 2. Change the version in `package.json` and in both root entries of | ||
| `package-lock.json`. Change nothing else, as other changes would be missing | ||
| from the changelog. | ||
|
|
||
| ## 3. Check | ||
|
|
||
| Run the checks listed in [`/commit`](../commit/SKILL.md) and read each command's | ||
| own exit code. | ||
|
|
||
| If `npm run test:playwright-ct:all` stops with `EBADDEVENGINES`, no tests ran. | ||
| This is a known problem ([#782](https://github.com/react-ui-org/react-ui/issues/782)). | ||
| Until it's fixed, run them directly and tell the user that the documented command | ||
| failed. Remove this fallback when #782 is closed. | ||
|
|
||
| ```sh | ||
| sudo docker compose -p "$COMPOSE_PROJECT_NAME" exec -T playwright sh -c \ | ||
| 'PATH="/workspace/node_modules/.bin:$PATH" playwright test -c playwright-ct.config.ts --update-snapshots=none' | ||
| ``` | ||
|
|
||
| ## 4. Hand over the draft | ||
|
|
||
| Stage the bump, then ask the user to check the draft on the | ||
| [releases page](https://github.com/react-ui-org/react-ui/releases). The API | ||
| token may not be able to see drafts, so a missing draft proves nothing. | ||
|
|
||
| * The draft's tag and title must be `vX.Y.Z`. On `BC` changes, release-drafter | ||
| proposes the next major (`v1.0.0`). If no draft matches when the PR merges, | ||
| the workflow publishes an empty release with no changelog. | ||
| * The user saves the draft without publishing it. | ||
|
|
||
| Give the user the expected changelog, grouped as in | ||
| [release-drafter.yml](../../../.github/release-drafter.yml): | ||
|
|
||
| ```markdown | ||
| ## ⚠️ Breaking Changes | ||
|
|
||
| - <PR title> by @<author> (PR #<number>) | ||
| ``` | ||
|
|
||
| Leave out PRs labelled `skip changelog`, and list anything worrying, such as | ||
| vulnerabilities GitHub reports on push. | ||
|
|
||
| ## 5. Commit and open the PR | ||
|
|
||
| When the user asks: | ||
|
|
||
| 1. Commit with `/commit`, using the message ``Bump version to `vX.Y.Z` ``. | ||
| 2. Push the branch. | ||
| 3. Open a PR into `master` with the same title and no AI attribution. Say that | ||
| merging it publishes the release. | ||
|
|
||
| ## 6. Confirm the release | ||
|
|
||
| If asked to watch the release after the merge, poll in the background. Run one | ||
| poll in the foreground first and check its output, because a poll that swallows | ||
| errors never reports anything. Don't assume `jq` is installed. | ||
|
|
||
| The release is out when all of these are true: | ||
|
|
||
| * The `release-management.yml` run for the bump commit has finished successfully, | ||
| including its npm and docs jobs. | ||
| * The GitHub release `vX.Y.Z` is not a draft and has the changelog. | ||
| * The npm registry lists the version as `latest` for `@react-ui-org/react-ui`. | ||
|
|
||
| Report any failed job as soon as you see it, and don't retry the publish. | ||
|
|
||
| Once the release is out, remind the user to archive the issues in the Done column | ||
| of [The Board](https://github.com/orgs/react-ui-org/projects/2). The GitHub MCP | ||
| had no project tools when this was written, so they must do it manually. | ||
|
|
||
| Check whether the available tools now include a GitHub project tool that can | ||
| archive items, including deferred tools. If so, tell the user and propose updating | ||
| this skill to archive the issues, with their approval on each run. | ||
Oops, something went wrong.
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.
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.
Could we please wrap this at 80 characters?
It is yaml syntax, so
should work