Skip to content

Commit 4374f88

Browse files
committed
Cache Go build and test
1 parent c1e8e98 commit 4374f88

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.github/workflows/coder.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,18 @@ jobs:
113113
with:
114114
go-version: "^1.17"
115115

116+
- uses: actions/cache@v2
117+
with:
118+
# Go mod cache, Linux build cache, Mac build cache, Windows build cache
119+
path: |
120+
~/go/pkg/mod
121+
~/.cache/go-build
122+
~/Library/Caches/go-build
123+
%LocalAppData%\go-build
124+
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
125+
restore-keys: |
126+
${{ runner.os }}-go-
127+
116128
- run: go install gotest.tools/gotestsum@latest
117129

118130
- run:

0 commit comments

Comments
 (0)