From d5570a1af7ea690a69327fd9eeaf9a5024da148e Mon Sep 17 00:00:00 2001 From: Axel Niklasson Yun Date: Thu, 2 Apr 2026 07:07:34 +0200 Subject: [PATCH 1/2] Add release instructions --- RELEASING.md | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 RELEASING.md diff --git a/RELEASING.md b/RELEASING.md new file mode 100644 index 0000000..428cde6 --- /dev/null +++ b/RELEASING.md @@ -0,0 +1,62 @@ +# Releasing + +This document describes how to create a new release of `linear-release`. + +## Prerequisites + +- You must be on the `main` branch with a clean working tree, up to date with `origin/main` +- The [GitHub CLI](https://cli.github.com) (`gh`) must be installed and authenticated +- `pnpm` must be installed + +## Creating a release + +Run the release script with the target version: + +```bash +pnpm release +``` + +For example: + +```bash +pnpm release 0.7.0 +``` + +The version must follow `MAJOR.MINOR.PATCH` format (e.g., `0.7.0`, `1.0.0`). + +## What happens + +The release script (`scripts/release.sh`) and CI workflows handle the full process: + +### 1. `pnpm release` (local) + +The script runs preflight checks and then: + +1. Validates that the version format is correct +2. Checks that `gh` is installed and authenticated +3. Verifies the working tree is clean, you're on `main`, and it's up to date with `origin/main` +4. Ensures the `v` tag and `release/` branch don't already exist +5. Creates a `release/` branch +6. Bumps the version in `package.json` +7. Commits the change and pushes the branch +8. Opens a PR against `main` via `gh pr create` + +### 2. PR review and merge + +Review and merge the PR as usual. The PR only contains the `package.json` version bump. + +### 3. Auto-tagging (CI) + +When a PR from a `release/*` branch is merged into `main`, the **Auto-tag release** workflow (`.github/workflows/auto-tag-release.yml`) runs automatically: + +1. Validates the version from the branch name matches `package.json` +2. Creates and pushes a `v` tag on the merge commit +3. Triggers the release workflow + +### 4. Build and publish (CI) + +The **Release** workflow (`.github/workflows/release.yml`) is triggered by the new tag and: + +1. Builds platform-specific executables (linux-x64, darwin-x64, darwin-arm64) using Bun +2. Code signs and notarizes the macOS binaries +3. Creates a GitHub Release with the built binaries attached From 7f9e0c230d8e09dcecb6e39c9fe227bfb548a11c Mon Sep 17 00:00:00 2001 From: Axel Niklasson Yun Date: Thu, 2 Apr 2026 09:16:39 +0200 Subject: [PATCH 2/2] Mention github action --- RELEASING.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/RELEASING.md b/RELEASING.md index 428cde6..f262bc4 100644 --- a/RELEASING.md +++ b/RELEASING.md @@ -60,3 +60,7 @@ The **Release** workflow (`.github/workflows/release.yml`) is triggered by the n 1. Builds platform-specific executables (linux-x64, darwin-x64, darwin-arm64) using Bun 2. Code signs and notarizes the macOS binaries 3. Creates a GitHub Release with the built binaries attached + +### 5. Update the GitHub action + +After publishing the new release, go to [linear-release-action](https://github.com/linear/linear-release-action) and update the [default pinned CLI version](https://github.com/linear/linear-release-action/blob/main/action.yml#L41) to the release you just created. When you've done so, publish a new release for the GitHub action as well.