Skip to content

Commit

Permalink
chore: update release instructions based on 1.20.5 release (denoland#…
Browse files Browse the repository at this point in the history
  • Loading branch information
dsherret committed Apr 8, 2022
1 parent a4c1e1b commit a4eee00
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 16 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/cargo_publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
- name: Clone repository
uses: actions/checkout@v2
with:
token: ${{ secrets.DENOBOT_PAT }}
submodules: recursive

- uses: dtolnay/rust-toolchain@stable
Expand All @@ -38,9 +39,11 @@ jobs:

- name: Create release tag and check forward commit to main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# the default secrets.GITHUB_TOKEN won't trigger a workflow run
# when tagging, but it will if we provide a custom PAT
GITHUB_TOKEN: ${{ secrets.DENOBOT_PAT }}
GH_WORKFLOW_ACTOR: ${{ github.actor }}
run: |
git config user.email "${{ github.actor }}@users.noreply.github.com"
git config user.name "${{ github.actor }}"
git config user.email "propelml@gmail.com"
git config user.name "denobot"
./tools/release/04_post_publish.ts
7 changes: 4 additions & 3 deletions .github/workflows/version_bump.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jobs:
- name: Clone repository
uses: actions/checkout@v2
with:
token: ${{ secrets.DENOBOT_PAT }}
submodules: recursive

- uses: dtolnay/rust-toolchain@stable
Expand All @@ -49,9 +50,9 @@ jobs:
- name: Create PR
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.DENOBOT_PAT }}
GH_WORKFLOW_ACTOR: ${{ github.actor }}
run: |
git config user.email "${{ github.actor }}@users.noreply.github.com"
git config user.name "${{ github.actor }}"
git config user.email "propelml@gmail.com"
git config user.name "denobot"
./tools/release/02_create_pr.ts
16 changes: 7 additions & 9 deletions tools/cut_a_release.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@
[`denoland/manual`](https://github.com/denoland/manual/)
- [ ] Ensure that external dependencies are up-to date in `denoland/deno` (e.g.
`rusty_v8`, `serde_v8`, `deno_doc`, `deno_lint`).
- [ ] Ownership access on crates.io for the 19 (🙀) crates that you will be
publishing. (Don't worry too much though as the main script publishing 18
of the crates allows recovery)
- [ ] Lot's of ☕

**During this process `main` branch (or any other branch that you're creating
Expand All @@ -29,7 +26,7 @@ Before starting the process write a message in company's #general channel:
## Updating `deno_std`

1. Go to the "version_bump" workflow in the deno_std repo's actions:
https://github.com/denoland/deno/actions/workflows/version_bump.yml
https://github.com/denoland/deno_std/actions/workflows/version_bump.yml

2. Click on the "Run workflow" button.
1. For the kind of release, select "minor".
Expand All @@ -51,9 +48,11 @@ relevant minor branch, so if you are cutting a `v1.17.3` release you need to
sync `v1.17` branch.

To do that, you need to cherry-pick commits from the main branch to the `v1.17`
branch. For patch releases we want to cherry-pick all commits that are not
`feat` commits. Check what was the last commit on `v1.17` branch before the
previous release and start cherry-picking newer commits from the `main`.
branch. For patch releases we want to cherry-pick all commits that do not add
features to the CLI. This generally means to filter out `feat` commits but not
necessarily (ex. `feat(core): ...`). Check what was the last commit on `v1.17`
branch before the previous release and start cherry-picking newer commits from
the `main`.

Once all relevant commits are cherry-picked, push the branch to the upstream and
verify on GitHub that everything looks correct.
Expand Down Expand Up @@ -125,8 +124,7 @@ queries the GitHub API to determine what it needs to change and update.

2. Checkout a new branch (e.g. `git checkout -b deno_1.17.0`).

3. Execute `./build.ts` (or
`deno run --config deno.jsonc --import-map import-map.json --allow-read=. --allow-write=./static --allow-net build.ts`).
3. Execute `deno task build`

4. Commit changes and raise a PR on `denoland/docland`.

Expand Down
2 changes: 1 addition & 1 deletion tools/release/01_bump_crate_versions.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env -S deno run --allow-read --allow-write --allow-run=cargo,git --allow-net --no-check
#!/usr/bin/env -S deno run --allow-read --allow-write --allow-run=cargo,git,deno --allow-net --no-check
// Copyright 2018-2022 the Deno authors. All rights reserved. MIT license.
import { DenoWorkspace } from "./deno_workspace.ts";
import { GitLogOutput, path, semver } from "./deps.ts";
Expand Down
1 change: 1 addition & 0 deletions tools/release/04_post_publish.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ async function forwardReleaseCommitToMain() {
return;
}

await repo.runCommandWithOutput(["git", "fetch", "origin", "main"]);
const releaseCommitHash =
(await repo.runCommand(["git", "rev-parse", "HEAD"])).trim();
const newBranchName = `forward_v${cliCrate.version}`;
Expand Down

0 comments on commit a4eee00

Please sign in to comment.