build: use go toolchain

This commit is contained in:
Michael Kriese 2024-12-04 10:12:38 +01:00
parent f8b0ccf1a3
commit 055854d1d7
No known key found for this signature in database
GPG key ID: F8D7748549A5986A
2 changed files with 13 additions and 1 deletions

View file

@ -44,6 +44,16 @@ jobs:
with:
go-version-file: go.mod
- name: validate go version
run: |
set -ex
toolchain=$(grep -oP '(?<=toolchain ).+' go.mod)
version=$(go version | cut -d' ' -f3)
if [ "$toolchain" != "$version" ]; then
echo "go version mismatch: $toolchain <> $version"
exit 1
fi
- run: make vet
- run: make build