build(deps): bump github.com/sashamelentyev/usestdlibvars from 1.17.1 to 1.19.0 (#3206)

Co-authored-by: Fernandez Ludovic <ldez@users.noreply.github.com>
This commit is contained in:
dependabot[bot] 2022-09-11 11:51:31 +00:00 committed by GitHub
parent 33a78c9266
commit 1f155b7ef6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 13 additions and 8 deletions

View File

@ -1755,6 +1755,9 @@ linters-settings:
# Suggest the use of tls.SignatureScheme.String()
# Default: false
tls-signature-scheme: true
# suggest the use of constant.Kind.String()
# Default: false
constant-kind: true
unparam:
# Inspect exported functions.

2
go.mod
View File

@ -78,7 +78,7 @@ require (
github.com/ryanrolds/sqlclosecheck v0.3.0
github.com/sanposhiho/wastedassign/v2 v2.0.6
github.com/sashamelentyev/interfacebloat v1.1.0
github.com/sashamelentyev/usestdlibvars v1.17.1
github.com/sashamelentyev/usestdlibvars v1.19.0
github.com/securego/gosec/v2 v2.13.1
github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c
github.com/shirou/gopsutil/v3 v3.22.8

4
go.sum generated
View File

@ -466,8 +466,8 @@ github.com/sanposhiho/wastedassign/v2 v2.0.6 h1:+6/hQIHKNJAUixEj6EmOngGIisyeI+T3
github.com/sanposhiho/wastedassign/v2 v2.0.6/go.mod h1:KyZ0MWTwxxBmfwn33zh3k1dmsbF2ud9pAAGfoLfjhtI=
github.com/sashamelentyev/interfacebloat v1.1.0 h1:xdRdJp0irL086OyW1H/RTZTr1h/tMEOsumirXcOJqAw=
github.com/sashamelentyev/interfacebloat v1.1.0/go.mod h1:+Y9yU5YdTkrNvoX0xHc84dxiN1iBi9+G8zZIhPVoNjQ=
github.com/sashamelentyev/usestdlibvars v1.17.1 h1:a9SrXLLCVY49g9hAEMfjpcN4sKV4SZ0rWABOAeRJBh0=
github.com/sashamelentyev/usestdlibvars v1.17.1/go.mod h1:EuR3x44678JCCOUOLGCc6/XeU5BFEYjcFO+in3qLyLM=
github.com/sashamelentyev/usestdlibvars v1.19.0 h1:xbpkUOXSd0TWpmSSqV4D+iky/oYGqzknSwBs5Nd1CNs=
github.com/sashamelentyev/usestdlibvars v1.19.0/go.mod h1:EuR3x44678JCCOUOLGCc6/XeU5BFEYjcFO+in3qLyLM=
github.com/securego/gosec/v2 v2.13.1 h1:7mU32qn2dyC81MH9L2kefnQyRMUarfDER3iQyMHcjYM=
github.com/securego/gosec/v2 v2.13.1/go.mod h1:EO1sImBMBWFjOTFzMWfTRrZW6M15gm60ljzrmy/wtHo=
github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c h1:W65qqJCIOVP4jpqPQ0YvHYKwcMEMVWIzWC5iNQQfBTU=

View File

@ -650,6 +650,7 @@ type UseStdlibVarsSettings struct {
OSDevNullFlag bool `mapstructure:"os-dev-null-flag"`
SQLIsolationLevelFlag bool `mapstructure:"sql-isolation-level-flag"`
TLSSignatureSchemeFlag bool `mapstructure:"tls-signature-scheme-flag"`
ConstantKind bool `mapstructure:"constant-kind"`
}
type UnparamSettings struct {

View File

@ -14,15 +14,16 @@ func NewUseStdlibVars(cfg *config.UseStdlibVarsSettings) *goanalysis.Linter {
cfgMap := make(map[string]map[string]interface{})
if cfg != nil {
cfgMap[a.Name] = map[string]interface{}{
analyzer.ConstantKindFlag: cfg.ConstantKind,
analyzer.CryptoHashFlag: cfg.CryptoHash,
analyzer.HTTPMethodFlag: cfg.HTTPMethod,
analyzer.HTTPStatusCodeFlag: cfg.HTTPStatusCode,
analyzer.TimeWeekdayFlag: cfg.TimeWeekday,
analyzer.TimeMonthFlag: cfg.TimeMonth,
analyzer.TimeLayoutFlag: cfg.TimeLayout,
analyzer.CryptoHashFlag: cfg.CryptoHash,
analyzer.RPCDefaultPathFlag: cfg.DefaultRPCPathFlag,
analyzer.OSDevNullFlag: cfg.OSDevNullFlag,
analyzer.RPCDefaultPathFlag: cfg.DefaultRPCPathFlag,
analyzer.SQLIsolationLevelFlag: cfg.SQLIsolationLevelFlag,
analyzer.TimeLayoutFlag: cfg.TimeLayout,
analyzer.TimeMonthFlag: cfg.TimeMonth,
analyzer.TimeWeekdayFlag: cfg.TimeWeekday,
analyzer.TLSSignatureSchemeFlag: cfg.TLSSignatureSchemeFlag,
}
}