docs(linter): comment why goheader is only enabled in the CI (#101)

This commit is contained in:
Quentin McGaw 2025-01-09 14:17:06 +01:00 committed by GitHub
parent efa14ab5d0
commit ce2cde5662
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 25 additions and 18 deletions

View file

@ -27,4 +27,8 @@ jobs:
with: with:
version: v1.60 version: v1.60
only-new-issues: true only-new-issues: true
# The goheader linter is enabled so that it runs only on modified or new files
# (see only-new-issues: true). Note it is disabled in .golangci.yml because
# golangci-lint is not aware of new/modified files compared to the last git commit,
# and we want to avoid reporting invalid goheader errors when running the linter locally.
args: --enable goheader args: --enable goheader

View file

@ -16,6 +16,9 @@ linters:
- gci - gci
- gocheckcompilerdirectives - gocheckcompilerdirectives
- gofmt - gofmt
# goheader is disabled but it is enabled in the CI with a flag.
# Please see .github/workflows/golangci-lint.yml which explains why.
# - goheader
- goimports - goimports
- gomodguard - gomodguard
- gosec - gosec
@ -72,8 +75,8 @@ linters-settings:
disabled: true disabled: true
issues: issues:
exclude-dirs-use-default: false exclude-dirs-use-default: false
exclude-rules: exclude-rules:
- path-except: libevm - path-except: libevm
linters: linters:
# If any issue is flagged in a non-libevm file, add the linter here # If any issue is flagged in a non-libevm file, add the linter here
@ -104,19 +107,19 @@ issues:
- varnamelen - varnamelen
- wastedassign - wastedassign
- whitespace - whitespace
include: include:
# Many of the default exclusions are because, verbatim "Annoying issue", # Many of the default exclusions are because, verbatim "Annoying issue",
# which defeats the point of a linter. # which defeats the point of a linter.
- EXC0002 - EXC0002
- EXC0004 - EXC0004
- EXC0005 - EXC0005
- EXC0006 - EXC0006
- EXC0007 - EXC0007
- EXC0008 - EXC0008
- EXC0009 - EXC0009
- EXC0010 - EXC0010
- EXC0011 - EXC0011
- EXC0012 - EXC0012
- EXC0013 - EXC0013
- EXC0014 - EXC0014
- EXC0015 - EXC0015