Skip to content

Commit efdbb1f

Browse files
authored
update setup-go to v4 and use its caching by default
1 parent da122ba commit efdbb1f

File tree

1 file changed

+4
-19
lines changed

1 file changed

+4
-19
lines changed

.github/workflows/test.yml

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -8,32 +8,17 @@ jobs:
88
os: [ubuntu-latest, macos-latest, windows-latest]
99
runs-on: ${{ matrix.os }}
1010
steps:
11-
- uses: actions/setup-go@v3
11+
- uses: actions/checkout@v3
12+
- uses: actions/setup-go@v4
1213
with:
1314
go-version: ${{ matrix.go-version }}
14-
- uses: actions/checkout@v3
1515
- run: go test ./...
1616

1717
test-cache:
1818
runs-on: ubuntu-latest
1919
steps:
20-
- uses: actions/setup-go@v3
21-
with:
22-
go-version: 1.20.x
2320
- uses: actions/checkout@v3
24-
- uses: actions/cache@v3
21+
- uses: actions/setup-go@v4
2522
with:
26-
# In order:
27-
# * Module download cache
28-
# * Build cache (Linux)
29-
# * Build cache (Mac)
30-
# * Build cache (Windows)
31-
path: |
32-
~/go/pkg/mod
33-
~/.cache/go-build
34-
~/Library/Caches/go-build
35-
~\AppData\Local\go-build
36-
key: ${{ runner.os }}-go-${{ matrix.go-version }}-${{ hashFiles('**/go.sum') }}
37-
restore-keys: |
38-
${{ runner.os }}-go-${{ matrix.go-version }}-
23+
go-version: 1.20.x
3924
- run: go test ./...

0 commit comments

Comments
 (0)