Template
1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo synced 2024-11-22 01:44:24 +01:00

Clean up revive linter config, tweak golangci output (#30980)

The `errorCode` and `warningCode` options were removed at some point,
they are not recognized by golangci-lint any more at least and they do
not match their published json schema. `confidence` and
`ignore-generated-header` are at the default value so does not need to
be configured.

https://golangci-lint.run/usage/linters/#revive
(cherry picked from commit 028992429a2e14de39c9bb028637948e446d23ad)
This commit is contained in:
silverwind 2024-05-18 10:53:28 +02:00 committed by Gergely Nagy
parent 50b4e7f26e
commit 99f29e59a1
No known key found for this signature in database

View file

@ -33,6 +33,8 @@ run:
output: output:
sort-results: true sort-results: true
sort-order: [file]
show-stats: true
linters-settings: linters-settings:
stylecheck: stylecheck:
@ -44,11 +46,7 @@ linters-settings:
- ifElseChain - ifElseChain
- singleCaseSwitch # Every time this occurred in the code, there was no other way. - singleCaseSwitch # Every time this occurred in the code, there was no other way.
revive: revive:
ignore-generated-header: false severity: error
severity: warning
confidence: 0.8
errorCode: 1
warningCode: 1
rules: rules:
- name: atomic - name: atomic
- name: bare-return - name: bare-return