Skip to content

Commit

Permalink
Doc: patch release instructions (#3598)
Browse files Browse the repository at this point in the history
add instructions to how to do a patch release
  • Loading branch information
abeatrix authored Mar 28, 2024
1 parent b61a315 commit a0056f2
Showing 1 changed file with 30 additions and 1 deletion.
31 changes: 30 additions & 1 deletion vscode/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ We also have some build-in UI to help during the development of autocomplete req

### Stable builds

To publish a new release to the [VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=sourcegraph.cody-ai) and [Open VSX Registry](https://open-vsx.org/extension/sourcegraph/cody-ai):
To publish a new **major** release to the [VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=sourcegraph.cody-ai) and [Open VSX Registry](https://open-vsx.org/extension/sourcegraph/cody-ai).

1. Increment the `version` in [`package.json`](package.json) & [`CHANGELOG`](CHANGELOG.md).
2. `pnpm update-agent-recordings` to update the version in agent recordings.
Expand All @@ -50,6 +50,35 @@ To publish a new release to the [VS Code Marketplace](https://marketplace.visual
6. Wait for the [vscode-stable-release workflow](https://github.com/sourcegraph/cody/actions/workflows/vscode-stable-release.yml) run to finish.
7. Update the [Release Notes](https://github.com/sourcegraph/cody/releases).

### Patch Release

To publish a **patch** release to the [VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=sourcegraph.cody-ai) and [Open VSX Registry](https://open-vsx.org/extension/sourcegraph/cody-ai).

1. Make sure all the changes for the patch are already committed to the `main` branch.
2. Create a patch release branch if one does not already exist:
1. For example, if you are releasing `v1.10.<patch>`, then you should look to see if there is already a `vscode/1.10` branch.
2. If there is not, then create the branch using the [last stable release tag](https://github.com/sourcegraph/cody/tags) for the version you are trying to patch, e.g., `git checkout vscode-v1.10.0 -B vscode/1.10` and push this branch.
1. Note: Do not push your changes to this branch directly; treat it like a `main` branch where all changes that are merged should be reviewed first.
3. Create a PR with your changes that will go into the release, and send that PR to the e.g., `vscode/1.10` branch:
1. Create your PR branch: `git checkout vscode/1.10 -b me/1.10.1-patch-release`
2. Make changes:
1. Cherry-pick (`git cherry-pick $COMMIT_FROM_MAIN`) the relevant patches from `main` into your PR branch. If there are any conflicts, address them in your branch.
2. Increment the `version` in [`package.json`](package.json)
3. Update the [`CHANGELOG`](CHANGELOG.md)
4. Update the version used in agent recordings by [following these steps](../agent/README.md#updating-the-polly-http-recordings)
3. Send a PR to merge your branch, e.g., `me/1.10.1-patch-release` into `vscode/1.10`
4. Ensure your PR branch passes CI tests, and get your PR reviewed/approved/merged.
4. Tag the patch release:
1. `git tag vscode-v$(jq -r .version package.json)`
2. `git push --tags`
5. Wait for the [vscode-stable-release workflow](https://github.com/sourcegraph/cody/actions/workflows/vscode-stable-release.yml) run to finish.
6. Once the patch has been published, update `main`:
1. Create a new PR branch off `main`
2. Update the `version` in [`package.json`](package.json) if appropriate.
3. Update the [`CHANGELOG`](CHANGELOG.md)
4. Update the version used in agent recordings by [following these steps](../agent/README.md#updating-the-polly-http-recordings)
5. Commit the version increment, e.g., `VS Code: Release 1.10.1` and get your `main` PR merged.

### Insiders builds

Insiders builds are nightly (or more frequent) builds with the latest from `main`. They're less stable but have the latest changes. Only use the insiders build if you want to test the latest changes.
Expand Down

0 comments on commit a0056f2

Please sign in to comment.