build: render the tap formula against any tag pin

The tap job matched the literal v0.1.0 url line, so bumping the pin
broke the release render. The pin is now matched generically and
marked in-source as a placeholder the workflow rewrites; the tap
always ships the release tarball with its real sha256.
This commit is contained in:
vhaudiquet committed 2026-10-31 18:35:55 -05:00
1 parent d14d8c07bd
commit 561a241e09
2 files changed
+2 -4

No files matched your search

+1 -2
View File
@@ -132,8 +132,7 @@ jobs:
sha="$(cut -d' ' -f1 "dist/ecrou-v$v-darwin-arm64.tar.gz.sha256")"
url="https://github.com/vhaudiquet/ecrou/archive/refs/tags/v$v.tar.gz"
mkdir -p formula/Formula
sed -e 's|^ # Pinned by tag until the first release exists; switch to the$| # Published by the ecrou release workflow; do not edit by hand.|' -e '/^ # release tarball + sha256 then\.$/d' -e "s|^ url \"https://github.com/vhaudiquet/ecrou.git\", tag: \"v0.1.0\"$| url \"$url\"\n sha256 \"$sha\"|" \
packaging/homebrew/Formula/ecrou.rb > formula/Formula/ecrou.rb
sed -e '/^ # Placeholder pin:/d' -e "s|^ url \"https://github.com/vhaudiquet/ecrou.git\", tag: \"v[0-9][0-9.]*\"$| url \"$url\"\n sha256 \"$sha\"|" packaging/homebrew/Formula/ecrou.rb > formula/Formula/ecrou.rb
grep -q "sha256 \"$sha\"" formula/Formula/ecrou.rb
git clone -q "https://x-access-token:$TAP_TOKEN@github.com/vhaudiquet/homebrew-ecrou" tap
cp formula/Formula/ecrou.rb tap/Formula/ecrou.rb
+1 -2
View File
@@ -5,8 +5,7 @@
class Ecrou < Formula
desc "a small microVM runtime based on libkrun"
homepage "https://github.com/vhaudiquet/ecrou"
# Pinned by tag until the first release exists; switch to the
# release tarball + sha256 then.
# Placeholder pin: the release workflow rewrites url and sha256 on publish.
url "https://github.com/vhaudiquet/ecrou.git", tag: "v0.1.0"
license "MIT"