Skip to content

feat: publish weaveffi to the shared Homebrew tap - #63

Merged
owenthcarey merged 5 commits into
mainfrom
feat/homebrew-tap
Nov 21, 2026
Merged

owenthcarey merged 5 commits into
mainfrom
feat/homebrew-tap

Conversation

@owenthcarey

@owenthcarey owenthcarey commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • release-binaries.yml gets a homebrew job that runs once every archive is attached. It downloads the published archives, uploads a SHA256SUMS asset, renders weaveffi.rb and attaches it to the release, then pushes Formula/weaveffi.rb to weavefoundry/homebrew-tap with HOMEBREW_TAP_TOKEN. The push writes only that file and retries after git pull --rebase, the same way WeaveC's does.
  • The tap is only updated when the tag is the latest release, so a workflow_dispatch rerun for an older tag can't downgrade the formula. If the token is missing, the job warns and skips the push.
  • packaging/homebrew/weaveffi.rb.in + scripts/render-formula.py (based on WeaveC's): on_macos/on_linux × on_arm/on_intel url/sha256 blocks, bin.install "weaveffi", the Bash/Zsh/fish completions via generate_completions_from_executable, and a test do that checks weaveffi --version against the formula version. There's no version line because brew audit --strict flags it as redundant with the URL.
  • Docs: brew install weavefoundry/tap/weaveffi in the README and Getting Started, a note in the completions guide that Homebrew installs them, and the release flow in CONTRIBUTING.

Closes #62

Test plan

  • Rendered the formula from the real v0.26.0 release archives; a missing archive fails with a clear error
  • Installed it through a temporary local tap on macOS arm64: brew install and brew test pass, and the bash/zsh/fish completions land in the Homebrew prefix (then uninstalled and untapped)
  • brew audit --strict --online and brew style are clean
  • scripts/check-links.sh passes
  • Updated documentation for user-facing changes
  • PR title follows Conventional Commits
  • The workflow change itself runs only on a release. actionlint wasn't run locally.

Notes for reviewers

  • HOMEBREW_TAP_TOKEN is already visible to this repository.
  • The tap README row for weaveffi lives in the other repository, so it's a separate PR there.
  • Linux and macOS x64 weren't installed locally. They use the same formula path, just different url/sha256 values.
  • To publish the formula for v0.26.0 without waiting for the next release, run the workflow manually: gh workflow run release-binaries.yml -f tag=v0.26.0. This also rebuilds and re-uploads that release's archives with --clobber.

CI repairs (unrelated to Homebrew)

Main's CI breaks on the current runners, so this PR also carries three small fixes, each in its own commit:

  • Rust 1.100: three tests now assert the ExitCode they used to drop. The completions/schema --version test moves from the binary's unit tests to tests/cli/schema.rs, because Cargo no longer gives a binary's own unit tests CARGO_BIN_EXE_weaveffi. fail_interface_not_sync.stderr picks up rustc's new note pointing at the field.
  • Cargo 1.100's build layout (fix(cli) commit): Cargo now builds each feature set into its own build/<package>/<hash>/out/ and has no deps/, so CargoCrate::lib_artifacts fell back to the shared uplifted copy, which a concurrent build with other features replaces. That's why extract::feature_flags_reach_the_library_build failed on Linux. It now finds the build's own file by matching contents, while holding a new {target_dir}/weaveffi/build.lock so another weaveffi command can't replace the uplifted copy first.
  • RUSTSEC-2026-0486: rustix 1.1.5 → 1.1.6.
  • Ubuntu 26.04: ubuntu-latest is now 26.04, which setup-swift doesn't support yet, so Swift's Linux conformance lane runs on ubuntu-24.04.

release-binaries.yml now adds a SHA256SUMS asset and a Homebrew formula,
rendered by scripts/render-formula.py from packaging/homebrew/weaveffi.rb.in,
once every archive is attached, and pushes Formula/weaveffi.rb to
weavefoundry/homebrew-tap with the HOMEBREW_TAP_TOKEN organization secret.

Closes #62
Rust 1.100 warns on an unused ExitCode, no longer gives a binary's unit
tests CARGO_BIN_EXE_weaveffi (so the completions test moves to the CLI
integration tests), and points the not-Sync diagnostic at the field.
swift-actions/setup-swift doesn't support Ubuntu 26.04, which
ubuntu-latest now is.
Cargo 1.100 builds each feature set into its own build/{package}/{hash}/out
directory and has no deps/ directory, so the library path fell back to the
uplifted copy that a concurrent build with other features replaces. Find
the build's own file instead, while holding a lock that keeps another
weaveffi command from replacing the uplifted copy first.
@owenthcarey
owenthcarey merged commit 5731932 into main Nov 21, 2026
53 of 55 checks passed
@owenthcarey
owenthcarey deleted the feat/homebrew-tap branch November 21, 2026 22:36
@owenthcarey
owenthcarey restored the feat/homebrew-tap branch November 27, 2026 06:40
@owenthcarey
owenthcarey deleted the feat/homebrew-tap branch November 27, 2026 06:40
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.

Publish weaveffi to the shared Homebrew tap

1 participant