Skip to content

feat: tag-triggered release pipeline + workmem version command#7

Merged
marlian merged 4 commits intomainfrom
feat/release-pipeline
Apr 16, 2026
Merged

feat: tag-triggered release pipeline + workmem version command#7
marlian merged 4 commits intomainfrom
feat/release-pipeline

Conversation

@marlian
Copy link
Copy Markdown
Owner

@marlian marlian commented Apr 16, 2026

Summary

  • Adds workmem version / --version / -v with ldflags-injected build metadata (version, commit, buildDate)
  • Adds .github/workflows/release.yml — tag-triggered (v*), matrix over 5 platforms (darwin/linux amd64+arm64, windows amd64), packages each binary + LICENSE + README into tar.gz/zip, generates SHA256SUMS, publishes a GitHub release with auto-generated notes. Detects pre-release tag suffixes (-rc, -alpha, -beta, -pre, -dev) and marks those as pre-releases.
  • Rewrites README Install section — three paths (Homebrew tap placeholder, direct download with checksum verification + Gatekeeper note, build from source + go install)
  • Fixes duplicated License line in README
  • IMPLEMENTATION.md Step 3.3 refreshed — CI cross-builds and release binaries checked off; Homebrew tap and fresh-machine validation remain open pending first actual release

Test plan

  • go build ./... + go test ./... green locally
  • Local packaging dry run: tar.gz produces workmem-<platform>-<version>/ directory containing workmem + LICENSE + README.md, and SHA256 is stable
  • workmem version / --version / -v all work without ldflags (reports "dev")
  • -ldflags -X main.version=v0.1.0 ... overrides correctly
  • First real tag push (will be v0.1.0 or v0.1.0-rc1) triggers the workflow end-to-end — to be verified post-merge
  • Homebrew tap formula (separate PR in marlian/homebrew-tap) after first release SHAs exist

🤖 Generated with Claude Code

Ships the release side of Step 3.3: tagging vX.Y.Z on main produces a
GitHub release with cross-platform archives + SHA256SUMS, and every
binary self-identifies via `workmem version`.

Changes:
- cmd/workmem: add `version`/`--version`/`-v` command. Build metadata
  (version, commit, buildDate) lives in package-level vars overridden
  at link time via `-ldflags -X main.version=...`. Source builds and
  `go install` report "workmem dev"; tagged release binaries report
  the real vX.Y.Z + 7-char commit SHA + ISO-8601 build timestamp.
- .github/workflows/release.yml: new workflow triggered on `v*` tag
  push. Matrix builds 5 targets (darwin/linux amd64+arm64, windows
  amd64), packages each as tar.gz (unix) or zip (windows) with the
  binary + LICENSE + README inside a top-level directory, uploads
  to a per-matrix artifact. Second job downloads all archives,
  generates SHA256SUMS, detects pre-release suffixes (rc/alpha/beta/
  pre/dev) and calls `gh release create --generate-notes` to publish.
- README.md: rewrite Install section with three paths — Homebrew tap
  (placeholder until the tap repo exists), direct download with
  SHA256SUMS verification + Gatekeeper note, build from source incl.
  `go install`. Fix a duplicated License line.
- IMPLEMENTATION.md: Step 3.3 items refreshed — CI cross-builds and
  release binaries now [x]; Homebrew tap and fresh-machine validation
  remain [ ] pending the first actual tag + tap repo creation.
Copilot AI review requested due to automatic review settings April 16, 2026 00:01
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a tag-triggered GitHub Releases pipeline and a CLI version surface so distributed binaries can report build metadata consistently across platforms.

Changes:

  • Added workmem version / --version / -v that prints ldflags-injected build metadata (version/commit/buildDate) plus Go runtime version.
  • Added .github/workflows/release.yml to cross-build and package 5 platform binaries on v* tags, generate SHA256SUMS, and publish a GitHub release (with prerelease detection).
  • Updated installation documentation (Homebrew placeholder, direct-download + checksum verification, source build) and refreshed release readiness checklist.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

File Description
cmd/workmem/main.go Adds build metadata variables and a version/--version/-v CLI path to print them.
README.md Rewrites Install section to reflect releases + checksum verification and adds version command example.
IMPLEMENTATION.md Updates Step 3.3 release pipeline checklist/details.
.github/workflows/release.yml Introduces tag-triggered cross-build, packaging, checksum generation, and GitHub Release publishing.

Comment thread cmd/workmem/main.go
Comment thread .github/workflows/release.yml Outdated
Two real catches:

- cmd/workmem: the local variable holding *mcpserver.Runtime in
  runMCP was named `runtime`, which shadows the stdlib `runtime`
  package now imported for `runtime.Version()`. Rename to `rt` so
  the shadowing is gone and future readers aren't confused about
  which `runtime` is in scope.
- .github/workflows/release.yml: the top-level directory inside
  the tar.gz/zip was `workmem-<os-arch>` but the README install
  commands extract into `workmem-<os-arch>-vX.Y.Z/`. Align the
  packaging so the dir inside the archive carries the version
  suffix too. Archive filename was already versioned, only the
  inner dir was out of sync.
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

Comment thread README.md Outdated
Comment thread IMPLEMENTATION.md Outdated
Comment thread README.md Outdated
- README: replace "single static binary" with "single self-contained
  binary, no external runtime dependencies". Go binaries with
  CGO_ENABLED=0 still link dynamically against libSystem on macOS
  and kernel32 on Windows; "static" was technically inaccurate.
- README: the `shasum --ignore-missing` flag does not exist on macOS
  shasum (only on GNU sha256sum). Switch the verification recipe to
  `grep "<archive>" SHA256SUMS | shasum -a 256 -c`, which only
  verifies the archive the user actually downloaded and works
  identically on macOS and Linux without GNU-specific flags.
- IMPLEMENTATION.md: the Step 3.3 CI cross-builds description read
  "darwin/linux/windows × amd64/arm64" but the matrix has no
  windows/arm64 target. Replace with the actual 5-target list to
  keep the doc honest about what ships.
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

Comment thread README.md Outdated
Comment thread .github/workflows/release.yml Outdated
- README: the single `shasum -a 256 -c` recipe does not work out of
  the box on Linux — many distros ship `sha256sum` (GNU coreutils)
  but not `shasum` (Perl-based BSD/macOS). Split the example into
  two blocks so the macOS verification uses `shasum` and the Linux
  one uses `sha256sum`, with archive names matching the typical
  platform for each.
- release.yml: the pre-release detection regex `-(rc|alpha|beta|pre|
  dev)` matched the suffix anywhere in the tag name, which would
  treat `v1.0.0-preview` as a pre-release because "-pre" appears
  in the middle. Anchor to end-of-string with `$` and allow
  optional trailing digits (e.g. `-rc1`, `-beta2`) so only
  genuinely pre-release suffixes trigger the flag.
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

@marlian marlian merged commit f748e6c into main Apr 16, 2026
12 checks passed
@marlian marlian deleted the feat/release-pipeline branch April 16, 2026 04:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants