Skip to content

Commit f5f1f29

Browse files
committed
Update Homebrew formula creation in GitHub Actions workflow to include versioning in build flags
- Modified the formula generation to pass the version as a build flag during the installation process. - Enhanced the formula for mcpproxy to ensure accurate versioning in the built binary.
1 parent 5cc9580 commit f5f1f29

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ jobs:
241241
mkdir -p Formula
242242
243243
# Create formula file
244-
printf 'class Mcpproxy < Formula\n desc "Smart MCP Proxy - Intelligent tool discovery and proxying for Model Context Protocol servers"\n homepage "https://github.com/smart-mcp-proxy/mcpproxy-go"\n url "https://github.com/smart-mcp-proxy/mcpproxy-go/archive/refs/tags/v%s.tar.gz"\n sha256 "%s"\n license "MIT"\n head "https://github.com/smart-mcp-proxy/mcpproxy-go.git"\n\n depends_on "go" => :build\n\n def install\n system "go", "build", "-ldflags", "-s -w", "-o", "mcpproxy", "./cmd/mcpproxy"\n bin.install "mcpproxy"\n end\n\n test do\n assert_match version.to_s, shell_output("#{bin}/mcpproxy --version")\n end\nend\n' "${VERSION}" "${SOURCE_SHA}" > Formula/mcpproxy.rb
244+
printf 'class Mcpproxy < Formula\n desc "Smart MCP Proxy - Intelligent tool discovery and proxying for Model Context Protocol servers"\n homepage "https://github.com/smart-mcp-proxy/mcpproxy-go"\n url "https://github.com/smart-mcp-proxy/mcpproxy-go/archive/refs/tags/v%s.tar.gz"\n sha256 "%s"\n license "MIT"\n head "https://github.com/smart-mcp-proxy/mcpproxy-go.git"\n\n depends_on "go" => :build\n\n def install\n system "go", "build", "-ldflags", "-s -w -X mcpproxy-go/cmd/mcpproxy.version=v%s", "-o", "mcpproxy", "./cmd/mcpproxy"\n bin.install "mcpproxy"\n end\n\n test do\n assert_match version.to_s, shell_output("#{bin}/mcpproxy --version")\n end\nend\n' "${VERSION}" "${SOURCE_SHA}" "${VERSION}" > Formula/mcpproxy.rb
245245
246246
echo "Formula created successfully"
247247
cat Formula/mcpproxy.rb

0 commit comments

Comments
 (0)