1name: CI23on:4 push:5 branches: [main]6 pull_request:7 workflow_dispatch:89permissions:10 contents: read1112concurrency:13 group: ci-${{ github.workflow }}-${{ github.ref }}14 cancel-in-progress: true1516jobs:17 check:18 name: Format, vet, lint, test (${{ matrix.os }})19 strategy:20 fail-fast: false21 matrix:22 os: [ubuntu-24.04, macos-15]23 runs-on: ${{ matrix.os }}24 timeout-minutes: 1525 steps:26 - name: Check out source27 uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.128 - name: Set up Go29 uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.030 with:31 go-version-file: go.mod32 cache: true33 - name: Check34 run: make check35 - name: Build36 run: make build3738 cross-build:39 name: Cross-compile release targets40 runs-on: ubuntu-24.0441 timeout-minutes: 1042 steps:43 - name: Check out source44 uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.145 - name: Set up Go46 uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.047 with:48 go-version-file: go.mod49 cache: true50 - name: Build every GOOS/GOARCH we ship51 run: |52 for target in darwin/amd64 darwin/arm64 linux/amd64 linux/arm64 windows/amd64 windows/arm64; do53 echo "building $target"54 GOOS=${target%/*} GOARCH=${target#*/} CGO_ENABLED=0 go build -trimpath -o /dev/null .55 done