-
Notifications
You must be signed in to change notification settings - Fork 36
Automated Release Process
Andy Berry edited this page Jun 24, 2014
·
5 revisions
- Release metadata is stored in
releases/<tag.version>.json
in the format:
{
"milestone": "milestoneId",
"name": "name of the release - probably the same as the tag",
"description": "release highlights",
"prerelease": true|false
}
- Freeform release notes are stored in
releases/<tag.version>.md
. This is a freeform text area in markdown format.
- CI runs the various tests and goes green
- Create an annotated tag for the commit that is released
- push the tag
- The build first finds all issues in the milestone that are closed using the GitHub API
- the milestoneID is in
releases/<tag>.json
GET https://api.github.com/repos/BladeRunnerJS/brjs/issues?milestone=<milestone>&state=closed
- only issues with set labels are included in this list, this is currently 'bug', 'feature', 'enhancement' or 'experience'. Issues labeled 'invalid', 'duplicate' or 'wont-fix' are ignored.
- the milestoneID is in
- It then appends this to the bottom of the markdown in
releases/<tag>.md
-
Trigger the release stage in CI
- This will calculate the latest annotate tag (the one we just made)
- using
git describe --abbrev=0
- using
- This will calculate the latest annotate tag (the one we just made)
- The build checks the release doesn't already exist
GET https://api.github.com/repos/BladeRunnerJS/brjs/releases
- if it does - it uses
PATCH
in the next step, otherwise we usePOST
- The build creates the release
<POST|PATCH> https://api.github.com/repos/BladeRunnerJS/brjs/releases
- The body of the request is (this is all taken from
release/<tag>.json
):
{
"tag_name": "<tag name>",
"name": "<release name>",
"body": "<RELEASE NOTES>"
"prerelease": true|false,
}
- store the upload_url from the response
- The build uses the
upload_url
field from the previous response as the URL for the zip upload