mirror of
https://github.com/tuneinsight/lattigo.git
synced 2025-09-13 03:27:14 +00:00
build: Bump Go version to 1.24 in CI and update staticcheck
This commit is contained in:
26
.github/workflows/ci.yml
vendored
26
.github/workflows/ci.yml
vendored
@@ -16,29 +16,29 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
go-version: '1.23.10'
|
go-version: '1.23.10'
|
||||||
|
|
||||||
- uses: actions/cache@v4
|
- uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: ~/go/pkg/mod
|
path: ~/go/pkg/mod
|
||||||
key: ${{ runner.os }}-go-tools-${{ hashFiles('**/go.sum') }}
|
key: ${{ runner.os }}-go-tools-${{ hashFiles('**/go.sum') }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-go-tools
|
${{ runner.os }}-go-tools
|
||||||
|
|
||||||
- name: Setup tools
|
|
||||||
run: make get_tools
|
|
||||||
|
|
||||||
- name: Run Makefile checks
|
- name: Setup tools
|
||||||
run: make checks
|
run: make get_tools
|
||||||
|
|
||||||
|
- name: Run Makefile checks
|
||||||
|
run: make checks
|
||||||
|
|
||||||
tests:
|
tests:
|
||||||
name: Run Go ${{ matrix.go }} tests
|
name: Run Go ${{ matrix.go }} tests
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
go: ['1.23.6', '1.22.11', '1.21.13']
|
go: ["1.24", "1.23", "1.22"]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v5
|
uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
|
|||||||
4
Makefile
4
Makefile
@@ -35,7 +35,7 @@ checks: check_tools
|
|||||||
false;\
|
false;\
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@STATICCHECKOUT=$$(staticcheck -go 1.23 -checks all ./...); \
|
@STATICCHECKOUT=$$(staticcheck -go 1.24 -checks all ./...); \
|
||||||
if [ -z "$$STATICCHECKOUT" ]; then\
|
if [ -z "$$STATICCHECKOUT" ]; then\
|
||||||
echo "staticcheck: OK";\
|
echo "staticcheck: OK";\
|
||||||
else \
|
else \
|
||||||
@@ -76,7 +76,7 @@ EXECUTABLES = goimports staticcheck govulncheck gosec
|
|||||||
.PHONY: get_tools
|
.PHONY: get_tools
|
||||||
get_tools:
|
get_tools:
|
||||||
go install golang.org/x/tools/cmd/goimports@latest
|
go install golang.org/x/tools/cmd/goimports@latest
|
||||||
go install honnef.co/go/tools/cmd/staticcheck@2024.1.1
|
go install honnef.co/go/tools/cmd/staticcheck@2025.1.1
|
||||||
go install golang.org/x/vuln/cmd/govulncheck@latest
|
go install golang.org/x/vuln/cmd/govulncheck@latest
|
||||||
go install github.com/securego/gosec/v2/cmd/gosec@latest
|
go install github.com/securego/gosec/v2/cmd/gosec@latest
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user