Skip to content
This repository has been archived by the owner on Aug 6, 2023. It is now read-only.

Commit

Permalink
Cover all files in go commands
Browse files Browse the repository at this point in the history
  • Loading branch information
kachick committed Jul 28, 2023
1 parent b404a3d commit a092394
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
10 changes: 4 additions & 6 deletions .github/workflows/ci-go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ jobs:
with:
go-version-file: 'go.mod'
cache-dependency-path: 'go.sum'
- run: go test
- run: go build -v -race
- run: go test ./...
- run: go build -v -race ./...
lint:
runs-on: ubuntu-latest
steps:
Expand All @@ -35,10 +35,8 @@ jobs:
with:
go-version-file: 'go.mod'
cache-dependency-path: 'go.sum'
- name: lint
run: go vet
- name: format
run: go fmt && git add --intent-to-add . && git diff --exit-code
- run: go vet ./...
- run: go fmt ./... && git add --intent-to-add . && git diff --exit-code
# Because of default in vscode extension
staticcheck:
runs-on: ubuntu-latest
Expand Down
6 changes: 3 additions & 3 deletions Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,18 @@ tasks:
- go build -o ./dist/nixpkgs-url ./cmd/nixpkgs-url
test:
cmds:
- go test
- go test ./...
fmt:
cmds:
- typos . .github .vscode --write-changes
- dprint fmt
- go fmt
- go fmt ./...
- nixpkgs-fmt ./*.nix
lint:
# go fmt does not have option for no effect - https://github.com/golang/go/issues/41189
cmds:
- dprint check
- go vet
- go vet ./...
- goreleaser check
- typos . .github .vscode
- nixpkgs-fmt --check ./*.nix
Expand Down

0 comments on commit a092394

Please sign in to comment.