File tree Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -1057,19 +1057,19 @@ linters-settings:
10571057 varnamelen :
10581058 # The longest distance, in source lines, that is being considered a "small scope." (defaults to 5)
10591059 # Variables used in at most this many lines will be ignored.
1060- max-distance : 5
1060+ max-distance : 6
10611061 # The minimum length of a variable's name that is considered "long." (defaults to 3)
10621062 # Variable names that are at least this long will be ignored.
1063- min-name-length : 3
1063+ min-name-length : 2
10641064 # Check method receiver names. (defaults to false)
10651065 check-receiver : false
10661066 # Check named return values. (defaults to false)
10671067 check-return : false
1068- # Ignore "ok" variables that hold the bool return value of a type assertion. (defaults to false )
1068+ # Ignore "ok" variables that hold the bool return value of a type assertion. (defaults to true )
10691069 ignore-type-assert-ok : false
1070- # Ignore "ok" variables that hold the bool return value of a map index. (defaults to false )
1070+ # Ignore "ok" variables that hold the bool return value of a map index. (defaults to true )
10711071 ignore-map-index-ok : false
1072- # Ignore "ok" variables that hold the bool return value of a channel receive. (defaults to false )
1072+ # Ignore "ok" variables that hold the bool return value of a channel receive. (defaults to true )
10731073 ignore-chan-recv-ok : false
10741074 # Optional list of variable names that should be ignored completely. (defaults to empty list)
10751075 ignore-names :
Original file line number Diff line number Diff line change @@ -81,6 +81,13 @@ var defaultLintersSettings = LintersSettings{
8181 Unparam : UnparamSettings {
8282 Algo : "cha" ,
8383 },
84+ Varnamelen : VarnamelenSettings {
85+ MaxDistance : 5 ,
86+ MinNameLength : 3 ,
87+ IgnoreTypeAssertOk : true ,
88+ IgnoreMapIndexOk : true ,
89+ IgnoreChanRecvOk : true ,
90+ },
8491 WSL : WSLSettings {
8592 StrictAppend : true ,
8693 AllowAssignAndCallCuddle : true ,
You can’t perform that action at this time.
0 commit comments