ci: use action/setup-go's cache (#1783)
* ci: use action/setup-go's cache * ci: deprecate Golang 1.14
This commit is contained in:
parent
7e289f46f1
commit
4065a33bfd
15
.github/workflows/test.yml
vendored
15
.github/workflows/test.yml
vendored
@ -13,10 +13,13 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
- uses: actions/setup-go@v3
|
- uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: '^1.19'
|
go-version: '^1.19'
|
||||||
check-latest: true
|
check-latest: true
|
||||||
|
cache: true
|
||||||
|
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
@ -33,7 +36,6 @@ jobs:
|
|||||||
- ubuntu
|
- ubuntu
|
||||||
- macOS
|
- macOS
|
||||||
go:
|
go:
|
||||||
- 14
|
|
||||||
- 15
|
- 15
|
||||||
- 16
|
- 16
|
||||||
- 17
|
- 17
|
||||||
@ -43,17 +45,12 @@ jobs:
|
|||||||
runs-on: ${{ matrix.platform }}-latest
|
runs-on: ${{ matrix.platform }}-latest
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
- uses: actions/setup-go@v3
|
- uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: 1.${{ matrix.go }}.x
|
go-version: 1.${{ matrix.go }}.x
|
||||||
|
cache: true
|
||||||
- uses: actions/checkout@v3
|
|
||||||
|
|
||||||
- uses: actions/cache@v3
|
|
||||||
with:
|
|
||||||
path: ~/go/pkg/mod
|
|
||||||
key: ${{ runner.os }}-1.${{ matrix.go }}.x-${{ hashFiles('**/go.sum') }}
|
|
||||||
restore-keys: ${{ runner.os }}-1.${{ matrix.go }}.x-
|
|
||||||
|
|
||||||
- run: |
|
- run: |
|
||||||
export GOBIN=$HOME/go/bin
|
export GOBIN=$HOME/go/bin
|
||||||
|
Loading…
Reference in New Issue
Block a user