ci: add cache
This commit is contained in:
parent
904a9f4a63
commit
eb0483734e
1 changed files with 21 additions and 1 deletions
|
@ -20,6 +20,16 @@ jobs:
|
||||||
with:
|
with:
|
||||||
go-version: '1.23.3'
|
go-version: '1.23.3'
|
||||||
|
|
||||||
|
- name: Setup cache
|
||||||
|
uses: actions/cache@v4
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.cache/go-build
|
||||||
|
~/go/pkg/mod
|
||||||
|
key: ${{ runner.os }}-golang-${{ hashFiles('**/go.sum') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-golang-
|
||||||
|
|
||||||
- name: Run Format Check
|
- name: Run Format Check
|
||||||
run: |
|
run: |
|
||||||
make format
|
make format
|
||||||
|
@ -29,13 +39,23 @@ jobs:
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Code
|
- name: Checkout Code
|
||||||
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:
|
||||||
go-version: '1.23.3'
|
go-version: '1.23.3'
|
||||||
|
|
||||||
|
- name: Setup cache
|
||||||
|
uses: actions/cache@v4
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.cache/go-build
|
||||||
|
~/go/pkg/mod
|
||||||
|
key: ${{ runner.os }}-golang-${{ hashFiles('**/go.sum') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-golang-
|
||||||
|
|
||||||
- name: Run Tests
|
- name: Run Tests
|
||||||
run: |
|
run: |
|
||||||
make test-coverage
|
make test-coverage
|
||||||
|
|
Loading…
Reference in a new issue