Skip to content

ci for packages

ci for packages #3

Workflow file for this run

name: Publish plugin artifacts
on:
push:
tags:
- "v*"
workflow_dispatch:
# Binaries are published to GitHub Releases (tag v*), not GitHub Packages.
# The "Upload build artifacts" step is CI-only (Actions run download); install scripts use Releases.
permissions:
contents: read
jobs:
mcp-call:
name: mcp-call
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
cache-dependency-path: go.sum
- name: Build release binaries
run: |
set -euo pipefail
mkdir -p dist
for spec in linux/amd64 linux/arm64 darwin/amd64 darwin/arm64; do
IFS=/ read -r goos goarch <<< "$spec"
out="dist/mcp-call-${goos}-${goarch}"
GOOS="$goos" GOARCH="$goarch" CGO_ENABLED=0 \
go build -trimpath -ldflags="-s -w" -o "$out" ./cmd/mcp-call
chmod +x "$out"
done
(cd dist && sha256sum mcp-call-* > checksums.txt)
- name: Upload CI artifacts (Actions tab only, not installable)
uses: actions/upload-artifact@v4
with:
name: mcp-call-binaries
path: dist/*
if-no-files-found: error
- name: Publish to GitHub Releases (install scripts download these)
if: github.ref_type == 'tag'
uses: softprops/action-gh-release@v2
with:
files: dist/*
generate_release_notes: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}