Merge pull request #958 from captainroy-hy/static-check-action

add staticcheck CI action
This commit is contained in:
Jianbo Sun
2021-01-29 18:14:56 +08:00
committed by GitHub
43 changed files with 136 additions and 115 deletions

View File

@@ -114,6 +114,25 @@ jobs:
- name: Run e2e tests
run: make e2e-test
staticcheck:
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: true
- name: Cache Go Dependencies
uses: actions/cache@v2
with:
path: .work/pkg
key: ${{ runner.os }}-pkg-${{ hashFiles('**/go.sum') }}
restore-keys: ${{ runner.os }}-pkg-
- name: Static Check
run: go run honnef.co/go/tools/cmd/staticcheck -- ./...
lint:
runs-on: ubuntu-20.04
@@ -164,4 +183,4 @@ jobs:
run: go install golang.org/x/tools/cmd/goimports && make fmt
- name: Check Diff
run: make check-diff
run: make check-diff