Skip to content

Commit

Permalink
Integrate golangci-lint with the CI pipeline
Browse files Browse the repository at this point in the history
Signed-off-by: timflannagan <[email protected]>
  • Loading branch information
timflannagan committed Oct 28, 2022
1 parent 9e85d83 commit e293fa3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/sanity.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v2
- uses: actions/setup-go@v3
with:
go-version-file: "go.mod"

- name: Cache build and module paths
uses: actions/cache@v3
Expand Down
12 changes: 9 additions & 3 deletions .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,27 @@ run:
linters:
enable:
- asciicheck
- deadcode
- bodyclose
- depguard
- errorlint
- gofmt
- goimports
- importas
- prealloc
- misspell
- nestif
- prealloc
- revive
- misspell
- stylecheck
- tparallel
- unconvert
- unparam
- unused
- whitespace

linters-settings:
errorlint:
errorf: false

importas:
alias:
- pkg: k8s.io/api/core/v1
Expand All @@ -30,6 +34,8 @@ linters-settings:
alias: metav1
- pkg: k8s.io/apimachinery/pkg/api/errors
alias: apierrors
- pkg: github.com/operator-framework/deppy/api/v1alpha1
alias: deppyv1alpha1
goimports:
local-prefixes: github.com/operator-framework/deppy

Expand Down

0 comments on commit e293fa3

Please sign in to comment.