Skip to content

Commit

Permalink
Linter: Disable shadow linting for ctx and err
Browse files Browse the repository at this point in the history
It's been a year, and I'm still getting caught out by govet demanding I
don't shadow a var I was deliberately shadowing.
Made worse by an increase in clashes with stylecheck when they both want
opposite things on the same line.
  • Loading branch information
gbjk committed Dec 18, 2024
1 parent 7d4be35 commit 0dd865c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,9 @@ issues:
- text: "Expect WriteFile permissions to be 0600 or less"
linters:
- gosec
- text: 'shadow: declaration of "(err|ctx)" shadows declaration at'
linters: [ govet ]


exclude-dirs:
- vendor
Expand Down

0 comments on commit 0dd865c

Please sign in to comment.