Skip to content

Commit 1f155b7

Browse files
build(deps): bump github.com/sashamelentyev/usestdlibvars from 1.17.1 to 1.19.0 (#3206)
Co-authored-by: Fernandez Ludovic <[email protected]>
1 parent 33a78c9 commit 1f155b7

File tree

5 files changed

+13
-8
lines changed

5 files changed

+13
-8
lines changed

.golangci.reference.yml

+3
Original file line numberDiff line numberDiff line change
@@ -1755,6 +1755,9 @@ linters-settings:
17551755
# Suggest the use of tls.SignatureScheme.String()
17561756
# Default: false
17571757
tls-signature-scheme: true
1758+
# suggest the use of constant.Kind.String()
1759+
# Default: false
1760+
constant-kind: true
17581761

17591762
unparam:
17601763
# Inspect exported functions.

go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ require (
7878
github.com/ryanrolds/sqlclosecheck v0.3.0
7979
github.com/sanposhiho/wastedassign/v2 v2.0.6
8080
github.com/sashamelentyev/interfacebloat v1.1.0
81-
github.com/sashamelentyev/usestdlibvars v1.17.1
81+
github.com/sashamelentyev/usestdlibvars v1.19.0
8282
github.com/securego/gosec/v2 v2.13.1
8383
github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c
8484
github.com/shirou/gopsutil/v3 v3.22.8

go.sum

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/config/linters_settings.go

+1
Original file line numberDiff line numberDiff line change
@@ -650,6 +650,7 @@ type UseStdlibVarsSettings struct {
650650
OSDevNullFlag bool `mapstructure:"os-dev-null-flag"`
651651
SQLIsolationLevelFlag bool `mapstructure:"sql-isolation-level-flag"`
652652
TLSSignatureSchemeFlag bool `mapstructure:"tls-signature-scheme-flag"`
653+
ConstantKind bool `mapstructure:"constant-kind"`
653654
}
654655

655656
type UnparamSettings struct {

pkg/golinters/usestdlibvars.go

+6-5
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,16 @@ func NewUseStdlibVars(cfg *config.UseStdlibVarsSettings) *goanalysis.Linter {
1414
cfgMap := make(map[string]map[string]interface{})
1515
if cfg != nil {
1616
cfgMap[a.Name] = map[string]interface{}{
17+
analyzer.ConstantKindFlag: cfg.ConstantKind,
18+
analyzer.CryptoHashFlag: cfg.CryptoHash,
1719
analyzer.HTTPMethodFlag: cfg.HTTPMethod,
1820
analyzer.HTTPStatusCodeFlag: cfg.HTTPStatusCode,
19-
analyzer.TimeWeekdayFlag: cfg.TimeWeekday,
20-
analyzer.TimeMonthFlag: cfg.TimeMonth,
21-
analyzer.TimeLayoutFlag: cfg.TimeLayout,
22-
analyzer.CryptoHashFlag: cfg.CryptoHash,
23-
analyzer.RPCDefaultPathFlag: cfg.DefaultRPCPathFlag,
2421
analyzer.OSDevNullFlag: cfg.OSDevNullFlag,
22+
analyzer.RPCDefaultPathFlag: cfg.DefaultRPCPathFlag,
2523
analyzer.SQLIsolationLevelFlag: cfg.SQLIsolationLevelFlag,
24+
analyzer.TimeLayoutFlag: cfg.TimeLayout,
25+
analyzer.TimeMonthFlag: cfg.TimeMonth,
26+
analyzer.TimeWeekdayFlag: cfg.TimeWeekday,
2627
analyzer.TLSSignatureSchemeFlag: cfg.TLSSignatureSchemeFlag,
2728
}
2829
}

0 commit comments

Comments
 (0)