snapshot of https://github.com/ent/ent.git (master, 2026-09-15; blobs > 131072B omitted)
This commit is contained in:
72
.golangci.yml
Normal file
72
.golangci.yml
Normal file
@@ -0,0 +1,72 @@
|
||||
run:
|
||||
go: '1.19'
|
||||
timeout: 5m
|
||||
|
||||
linters-settings:
|
||||
errcheck:
|
||||
ignore: fmt:.*,Read|Write|Close|Exec,io:Copy
|
||||
dupl:
|
||||
threshold: 100
|
||||
funlen:
|
||||
lines: 200
|
||||
statements: 200
|
||||
goheader:
|
||||
template: |-
|
||||
Copyright 2019-present Facebook Inc. All rights reserved.
|
||||
This source code is licensed under the Apache 2.0 license found
|
||||
in the LICENSE file in the root directory of this source tree.
|
||||
linters:
|
||||
disable-all: true
|
||||
enable:
|
||||
- asciicheck
|
||||
- bodyclose
|
||||
- dogsled
|
||||
- dupl
|
||||
- errcheck
|
||||
- funlen
|
||||
- gocritic
|
||||
# - gofmt; Enable back when upgrading CI to Go 1.20.
|
||||
- goheader
|
||||
- gosec
|
||||
- gosimple
|
||||
- govet
|
||||
- ineffassign
|
||||
- misspell
|
||||
- staticcheck
|
||||
- stylecheck
|
||||
- typecheck
|
||||
- unconvert
|
||||
- unused
|
||||
- whitespace
|
||||
|
||||
issues:
|
||||
exclude-rules:
|
||||
- path: _test\.go
|
||||
linters:
|
||||
- dupl
|
||||
- funlen
|
||||
- gosec
|
||||
- gocritic
|
||||
- linters:
|
||||
- unused
|
||||
source: ent.Schema
|
||||
- path: dialect/sql/schema
|
||||
linters:
|
||||
- dupl
|
||||
- gosec
|
||||
- text: "Expect WriteFile permissions to be 0600 or less"
|
||||
linters:
|
||||
- gosec
|
||||
- path: privacy/privacy.go
|
||||
linters:
|
||||
- stylecheck
|
||||
- path: entc/load/schema.go
|
||||
linters:
|
||||
- staticcheck
|
||||
- path: entc/gen/graph.go
|
||||
linters:
|
||||
- gocritic
|
||||
- path: \.go
|
||||
linters:
|
||||
- staticcheck
|
||||
text: SA1019
|
||||
Reference in New Issue
Block a user