|
| 1 | +# Releasing Sentire |
| 2 | + |
| 3 | +This guide covers the steps to cut a new release and the verification you |
| 4 | +should perform on each public install path before announcing the version. |
| 5 | + |
| 6 | +The release pipeline itself is automated: pushing a tag matching `v*` to |
| 7 | +GitHub triggers the `Release` workflow, which runs the test suite and then |
| 8 | +invokes [GoReleaser](https://goreleaser.com) (see `.goreleaser.yaml`) to |
| 9 | +build cross-platform archives, publish them to the GitHub release page, and |
| 10 | +update the [Homebrew tap](https://github.com/andreagrandi/homebrew-tap). |
| 11 | + |
| 12 | +For the version-bump and tagging workflow itself, see |
| 13 | +`.opencode/agent/new-release.md`. |
| 14 | + |
| 15 | +## Pre-release smoke tests |
| 16 | + |
| 17 | +Before tagging, run the local smoke tests. Neither requires Sentry |
| 18 | +credentials. |
| 19 | + |
| 20 | +```bash |
| 21 | +# Verifies the public `go install` path against the local module. |
| 22 | +make smoke-install |
| 23 | + |
| 24 | +# Builds a full goreleaser snapshot, extracts the current OS/arch archive, |
| 25 | +# and runs `sentire version` and `sentire --help` against the unpacked |
| 26 | +# binary. Requires goreleaser to be installed locally (`brew install |
| 27 | +# goreleaser`). |
| 28 | +make smoke-release |
| 29 | +``` |
| 30 | + |
| 31 | +`make smoke-install` runs as part of normal development (it is included in |
| 32 | +`make test` via `TestGoInstallSmoke`). `make smoke-release` is opt-in |
| 33 | +because a full snapshot build cross-compiles for every supported platform |
| 34 | +and adds noticeable time; it is also skipped automatically when goreleaser |
| 35 | +is not on PATH, so it does not break CI environments that lack it. |
| 36 | + |
| 37 | +## Post-release verification |
| 38 | + |
| 39 | +After the `Release` workflow finishes, verify each advertised install path |
| 40 | +end to end. Replace `<version>` with the tag you just pushed (without the |
| 41 | +leading `v` for `go install` queries; with it for the GitHub release page). |
| 42 | + |
| 43 | +### 1. GitHub release artifacts |
| 44 | + |
| 45 | +1. Open the release page: |
| 46 | + <https://github.com/andreagrandi/sentire/releases/tag/v\<version\>> |
| 47 | +2. Confirm archives for `Darwin_x86_64`, `Darwin_arm64`, `Linux_x86_64`, |
| 48 | + `Linux_arm64`, and `Windows_x86_64` are attached, along with |
| 49 | + `checksums.txt`. |
| 50 | +3. Download the archive for your platform, extract it, and run: |
| 51 | + |
| 52 | + ```bash |
| 53 | + ./sentire version # should print "sentire version <version>" |
| 54 | + ./sentire --help # should print top-level usage |
| 55 | + ``` |
| 56 | + |
| 57 | +### 2. `go install` |
| 58 | + |
| 59 | +In a clean shell (no `SENTRY_API_TOKEN` set), run: |
| 60 | + |
| 61 | +```bash |
| 62 | +GOBIN="$(mktemp -d)" |
| 63 | +export GOBIN |
| 64 | +go install github.com/andreagrandi/sentire/cmd/sentire@v<version> |
| 65 | +"$GOBIN/sentire" version # should report v<version> |
| 66 | +"$GOBIN/sentire" --help |
| 67 | +``` |
| 68 | + |
| 69 | +If `go install @latest` should also resolve to the new tag, run the same |
| 70 | +check with `@latest`. |
| 71 | + |
| 72 | +### 3. Homebrew |
| 73 | + |
| 74 | +The release workflow pushes an updated formula to |
| 75 | +`andreagrandi/homebrew-tap`. After the workflow finishes, verify the tap |
| 76 | +end to end: |
| 77 | + |
| 78 | +```bash |
| 79 | +brew update |
| 80 | +brew install andreagrandi/tap/sentire # or `brew upgrade ...` if installed |
| 81 | +sentire version # should report the new version |
| 82 | +sentire --help |
| 83 | +``` |
| 84 | + |
| 85 | +If the formula has not yet been updated, the workflow log under |
| 86 | +`Release → goreleaser` will show the push to the tap repository — check |
| 87 | +both this repo's Actions tab and the tap repo's commit history. |
| 88 | + |
| 89 | +## Troubleshooting |
| 90 | + |
| 91 | +- **`go install` returns an older version.** Module proxies cache versions; |
| 92 | + `GOPROXY=direct go install github.com/andreagrandi/sentire/cmd/sentire@v<version>` |
| 93 | + forces a fresh fetch from GitHub. |
| 94 | +- **`brew install` reports "no such formula".** The tap may not be tapped |
| 95 | + yet. Run `brew tap andreagrandi/tap` first, or use the fully qualified |
| 96 | + formula name `andreagrandi/tap/sentire`. |
| 97 | +- **`sentire version` reports `unknown` or a stale version.** The release |
| 98 | + archives are built with ldflags that inject the version |
| 99 | + (`internal/version.Version`). If the value is wrong, the goreleaser |
| 100 | + config drifted — check `.goreleaser.yaml` and the most recent commit on |
| 101 | + the tag. |
0 commit comments