-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
reordered CI and changed staticcheck version
- Loading branch information
Showing
1 changed file
with
14 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,35 +25,36 @@ jobs: | |
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Run Go tests | ||
run: go test -v -race -coverprofile coverage.txt -covermode atomic ./... | ||
|
||
- name: Build with duitdraw on non-windows systems | ||
if: matrix.os != 'windows-latest' | ||
run: go get -tags 'duitdraw mux9p' -t -v ./... | ||
- name: Check gofmt | ||
run: diff -u <(echo -n) <(gofmt -d -s .) | ||
shell: bash | ||
|
||
- name: Run go vet | ||
run: go vet . | ||
|
||
- name: Install staticcheck and misspell | ||
run: | | ||
go install honnef.co/go/tools/cmd/staticcheck@v0.4.2 | ||
go install honnef.co/go/tools/cmd/staticcheck@v0.5.1 | ||
go install github.com/client9/misspell/cmd/[email protected] | ||
working-directory: / | ||
shell: bash | ||
|
||
- name: Check if 'go get' modified go.mod file | ||
run: git diff --exit-code | ||
|
||
- name: Run staticcheck | ||
run: staticcheck -checks inherit,-U1000,-SA4003 ./... | ||
|
||
- name: Run misspell | ||
run: misspell -error . | ||
|
||
- name: Check gofmt | ||
run: diff -u <(echo -n) <(gofmt -d -s .) | ||
shell: bash | ||
- name: Run Go tests | ||
run: go test -v -race -coverprofile coverage.txt -covermode atomic ./... | ||
|
||
- name: Build with duitdraw on non-windows systems | ||
if: matrix.os != 'windows-latest' | ||
run: go get -tags 'duitdraw mux9p' -t -v ./... | ||
|
||
|
||
- name: Check if 'go get' modified go.mod file | ||
run: git diff --exit-code | ||
|
||
- name: Upload coverage to codecov | ||
# codecov can't seem to combine reports from multiple OSes correctly | ||
|