Skip to content

Commit

Permalink
Use caching in GHA
Browse files Browse the repository at this point in the history
  • Loading branch information
pgavlin committed Apr 11, 2024
1 parent 44a6200 commit e91bd5e
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
on: [push, pull_request]
on:
push:
branches:
- main
pull_request:
name: Test
jobs:
test:
Expand All @@ -22,8 +26,18 @@ jobs:
uses: actions/checkout@v4
- name: Bootstrap
run: go install ./cmd/dawn
- name: Restore cache
uses: actions/cache/restore@v3
with:
path: .dawn/build
key: dawn-build-${{ github.ref }}
- name: Build
run: dawn
- name: Save cache
uses: actions/cache/save@v3
with:
path: .dawn/build
key: dawn-build-${{ github.ref }}
- name: Test
run: go test ./... -coverprofile=coverage.out
- name: Upload coverage data
Expand Down

0 comments on commit e91bd5e

Please sign in to comment.