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

Commit

Permalink
Add revive linter with recommended config
Browse files Browse the repository at this point in the history
  • Loading branch information
lucacome committed Jul 1, 2021
1 parent f7924cb commit a42e3ba
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,33 @@
linters-settings:
misspell:
locale: US
revive:
ignore-generated-header: true
rules:
- name: blank-imports
- name: context-as-argument
- name: context-keys-type
- name: dot-imports
- name: empty-block
- name: error-naming
- name: error-return
- name: error-strings
- name: errorf
- name: exported
- name: if-return
- name: increment-decrement
- name: indent-error-flow
- name: package-comments
- name: range
- name: receiver-naming
- name: redefines-builtin-id
- name: superfluous-else
- name: time-naming
- name: unexported-return
- name: unreachable-code
- name: unused-parameter
- name: var-declaration
- name: var-naming

linters:
enable:
Expand All @@ -20,6 +47,7 @@ linters:
- nilerr
- noctx
- predeclared
- revive
- staticcheck
- structcheck
- typecheck
Expand Down

0 comments on commit a42e3ba

Please sign in to comment.