Skip to content

Bump actions/setup-go from 6.5.0 to 7.0.0 (#666) #932

Bump actions/setup-go from 6.5.0 to 7.0.0 (#666)

Bump actions/setup-go from 6.5.0 to 7.0.0 (#666) #932

Workflow file for this run

name: build
on:
push:
branches: ["master"]
release:
types: ["published"]
pull_request:
branches: ["master"]
env:
GOLANG_VERSION: "1.25"
jobs:
build:
name: Build ${{ matrix.variant.name }}
runs-on: ubuntu-latest
permissions:
contents: write
strategy:
matrix:
variant:
- {"name": "ha_amd64", "args": "GOARCH=amd64"}
- {"name": "ha_aarch64", "args": "GOARCH=arm64"}
steps:
- name: Checkout the repository
uses: actions/checkout@v7.0.0
- name: Setup go ${{ env.GOLANG_VERSION }}
uses: actions/setup-go@v7.0.0
with:
go-version: ${{ env.GOLANG_VERSION }}
- name: Build ${{ matrix.variant.name }}
run: CGO_ENABLED=0 ${{ matrix.variant.args }} go build -ldflags="-s -w" -o "${{ matrix.variant.name }}"
- name: Upload release asset
if: github.event_name == 'release'
env:
GH_TOKEN: ${{ github.token }}
run: gh release upload "${{ github.event.release.tag_name }}" "${{ matrix.variant.name }}" --clobber