1
0
mirror of https://github.com/go-kratos/kratos.git synced 2025-03-17 21:07:54 +02:00

enh(ci): Improve efficiency.

This commit is contained in:
Psnail 2020-09-19 20:54:41 +08:00 committed by GitHub
parent 3bf1be993b
commit 65ed153eb0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,6 +27,17 @@ jobs:
- name: Check out code into the Go module directory
uses: actions/checkout@v2
- name: Cache dependencies
uses: actions/cache@v2
with:
# Cache
path: ~/go/pkg/mod
# Cache key
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
# An ordered list of keys to use for restoring the cache if no cache hit occurred for key
restore-keys: |
${{ runner.os }}-go-
- name: Get dependencies
run: |
go get -v -t -d ./...
@ -48,8 +59,13 @@ jobs:
- name: Build
run: go build ./...
- name: Test
run: go test ./...
run: go test ./... -coverprofile=coverage.txt -covermode=atomic
- name: Coverage
run: bash <(curl -s https://codecov.io/bash)
- name: Tool
run: |
go install ./...