build(deps): bump go-simpler.org/sloglint from 0.3.0 to 0.4.0 (#4257)
Co-authored-by: Fernandez Ludovic <ldez@users.noreply.github.com>
This commit is contained in:
parent
5083ba8cfe
commit
27e99b5dbc
@ -1855,10 +1855,13 @@ linters-settings:
|
||||
- github.com/jmoiron/sqlx
|
||||
|
||||
sloglint:
|
||||
# Enforce using key-value pairs only (incompatible with attr-only).
|
||||
# Enforce not mixing key-value pairs and attributes.
|
||||
# Default: true
|
||||
no-mixed-args: false
|
||||
# Enforce using key-value pairs only (overrides no-mixed-args, incompatible with attr-only).
|
||||
# Default: false
|
||||
kv-only: true
|
||||
# Enforce using attributes only (incompatible with kv-only).
|
||||
# Enforce using attributes only (overrides no-mixed-args, incompatible with kv-only).
|
||||
# Default: false
|
||||
attr-only: true
|
||||
# Enforce using methods that accept a context.
|
||||
|
4
go.mod
4
go.mod
@ -121,7 +121,7 @@ require (
|
||||
github.com/ykadowak/zerologlint v0.1.5
|
||||
gitlab.com/bosi/decorder v0.4.1
|
||||
go-simpler.org/musttag v0.8.0
|
||||
go-simpler.org/sloglint v0.3.0
|
||||
go-simpler.org/sloglint v0.4.0
|
||||
golang.org/x/exp v0.0.0-20230510235704-dd950f8aeaea
|
||||
golang.org/x/tools v0.16.1
|
||||
gopkg.in/yaml.v3 v3.0.1
|
||||
@ -138,7 +138,7 @@ require (
|
||||
github.com/cespare/xxhash/v2 v2.1.2 // indirect
|
||||
github.com/chavacava/garif v0.1.0 // indirect
|
||||
github.com/davecgh/go-spew v1.1.1 // indirect
|
||||
github.com/ettle/strcase v0.1.1 // indirect
|
||||
github.com/ettle/strcase v0.2.0 // indirect
|
||||
github.com/fatih/structtag v1.2.0 // indirect
|
||||
github.com/fsnotify/fsnotify v1.5.4 // indirect
|
||||
github.com/go-ole/go-ole v1.2.6 // indirect
|
||||
|
8
go.sum
generated
8
go.sum
generated
@ -139,8 +139,8 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.m
|
||||
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
|
||||
github.com/esimonov/ifshort v1.0.4 h1:6SID4yGWfRae/M7hkVDVVyppy8q/v9OuxNdmjLQStBA=
|
||||
github.com/esimonov/ifshort v1.0.4/go.mod h1:Pe8zjlRrJ80+q2CxHLfEOfTwxCZ4O+MuhcHcfgNWTk0=
|
||||
github.com/ettle/strcase v0.1.1 h1:htFueZyVeE1XNnMEfbqp5r67qAN/4r6ya1ysq8Q+Zcw=
|
||||
github.com/ettle/strcase v0.1.1/go.mod h1:hzDLsPC7/lwKyBOywSHEP89nt2pDgdy+No1NBA9o9VY=
|
||||
github.com/ettle/strcase v0.2.0 h1:fGNiVF21fHXpX1niBgk0aROov1LagYsOwV/xqKDKR/Q=
|
||||
github.com/ettle/strcase v0.2.0/go.mod h1:DajmHElDSaX76ITe3/VHVyMin4LWSJN5Z909Wp+ED1A=
|
||||
github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM=
|
||||
github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE=
|
||||
github.com/fatih/structtag v1.2.0 h1:/OdNE99OxoI/PqaW/SuSK9uxxT3f/tcSZgon/ssNSx4=
|
||||
@ -591,8 +591,8 @@ gitlab.com/bosi/decorder v0.4.1/go.mod h1:jecSqWUew6Yle1pCr2eLWTensJMmsxHsBwt+PV
|
||||
go-simpler.org/assert v0.7.0 h1:OzWWZqfNxt8cLS+MlUp6Tgk1HjPkmgdKBq9qvy8lZsA=
|
||||
go-simpler.org/musttag v0.8.0 h1:DR4UTgetNNhPRNo02rkK1hwDTRzAPotN+ZqYpdtEwWc=
|
||||
go-simpler.org/musttag v0.8.0/go.mod h1:fiNdCkXt2S6je9Eblma3okjnlva9NT1Eg/WUt19rWu8=
|
||||
go-simpler.org/sloglint v0.3.0 h1:E6TR0w4io+F1mkdvFaCRKEpf19S2+lnEYiDM2Z6bClk=
|
||||
go-simpler.org/sloglint v0.3.0/go.mod h1:/RQr0TeTf89IyRjLJ9ogUbIp1Zs5zJJAj02pwQoDQdg=
|
||||
go-simpler.org/sloglint v0.4.0 h1:UVJuUJo63iNQNFEOtZ6o1xAgagVg/giVLLvG9nNLobI=
|
||||
go-simpler.org/sloglint v0.4.0/go.mod h1:v6zJ++j/thFPhefs2wEXoCKwT10yo5nkBDYRCXyqgNQ=
|
||||
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
|
||||
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
|
||||
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
|
||||
|
@ -120,6 +120,7 @@ var defaultLintersSettings = LintersSettings{
|
||||
Qualified: false,
|
||||
},
|
||||
SlogLint: SlogLintSettings{
|
||||
NoMixedArgs: true,
|
||||
KVOnly: false,
|
||||
AttrOnly: false,
|
||||
ContextOnly: false,
|
||||
@ -753,6 +754,7 @@ type RowsErrCheckSettings struct {
|
||||
}
|
||||
|
||||
type SlogLintSettings struct {
|
||||
NoMixedArgs bool `mapstructure:"no-mixed-args"`
|
||||
KVOnly bool `mapstructure:"kv-only"`
|
||||
AttrOnly bool `mapstructure:"attr-only"`
|
||||
ContextOnly bool `mapstructure:"context-only"`
|
||||
|
@ -12,6 +12,7 @@ func NewSlogLint(settings *config.SlogLintSettings) *goanalysis.Linter {
|
||||
var opts *sloglint.Options
|
||||
if settings != nil {
|
||||
opts = &sloglint.Options{
|
||||
NoMixedArgs: settings.NoMixedArgs,
|
||||
KVOnly: settings.KVOnly,
|
||||
AttrOnly: settings.AttrOnly,
|
||||
ContextOnly: settings.ContextOnly,
|
||||
|
Loading…
x
Reference in New Issue
Block a user