@@ -121,7 +121,7 @@ linters:
121
121
- wsl
122
122
- zerologlint
123
123
124
- # Disable specific linter
124
+ # Disable specific linter.
125
125
# https://golangci-lint.run/usage/linters/#disabled-by-default
126
126
disable :
127
127
- asasalint
@@ -266,7 +266,7 @@ linters:
266
266
# Default: 10
267
267
max-complexity : 10
268
268
# The maximal average package complexity.
269
- # If it's higher than 0.0 (float) the check is enabled
269
+ # If it's higher than 0.0 (float) the check is enabled.
270
270
# Default: 0.0
271
271
package-average : 0.5
272
272
@@ -279,7 +279,7 @@ linters:
279
279
- var
280
280
- func
281
281
282
- # If true, underscore vars (vars with "_" as the name) will be ignored at all checks
282
+ # If true, underscore vars (vars with "_" as the name) will be ignored at all checks.
283
283
# Default: false (underscore vars are not ignored)
284
284
ignore-underscore-vars : false
285
285
@@ -295,15 +295,15 @@ linters:
295
295
# Default: true (disabled)
296
296
disable-dec-num-check : false
297
297
298
- # If true, type declarations will be ignored for dec num check
298
+ # If true, type declarations will be ignored for dec num check.
299
299
# Default: false (type statements are not ignored)
300
300
disable-type-dec-num-check : false
301
301
302
- # If true, const declarations will be ignored for dec num check
302
+ # If true, const declarations will be ignored for dec num check.
303
303
# Default: false (const statements are not ignored)
304
304
disable-const-dec-num-check : false
305
305
306
- # If true, var declarations will be ignored for dec num check
306
+ # If true, var declarations will be ignored for dec num check.
307
307
# Default: false (var statements are not ignored)
308
308
disable-var-dec-num-check : false
309
309
@@ -428,7 +428,7 @@ linters:
428
428
# See the https://github.com/polyfloyd/go-errorlint for caveats.
429
429
# Default: true
430
430
errorf : false
431
- # Permit more than 1 %w verb, valid per Go 1.20 (Requires errorf:true)
431
+ # Permit more than 1 %w verb, valid per Go 1.20 (requires ` errorf: true`).
432
432
# Default: true
433
433
errorf-multi : false
434
434
# Check for plain type assertions and type switches.
@@ -508,7 +508,7 @@ linters:
508
508
# Optional message that gets included in error reports.
509
509
- pattern : ^fmt\.Print.*$
510
510
msg : Do not commit print statements.
511
- # Alternatively, put messages at the end of the regex, surrounded by `(# )?`
511
+ # Alternatively, put messages at the end of the regex, surrounded by `(# )?`.
512
512
# Escape any special characters. Those messages get included in error reports.
513
513
- pattern : ' fmt\.Print.*(# Do not commit print statements\.)?'
514
514
# Forbid spew Dump, whether it is called as function or method.
@@ -563,11 +563,11 @@ linters:
563
563
# Default: false
564
564
suppress-async-assertion : true
565
565
566
- # Suppress warning for comparing values from different types, like `int32` and `uint32`
566
+ # Suppress warning for comparing values from different types, like `int32` and `uint32`.
567
567
# Default: false
568
568
suppress-type-compare-assertion : true
569
569
570
- # Trigger warning for ginkgo focus containers like `FDescribe`, `FContext`, `FWhen` or `FIt`
570
+ # Trigger warning for ginkgo focus containers like `FDescribe`, `FContext`, `FWhen` or `FIt`.
571
571
# Default: false
572
572
forbid-focus-container : true
573
573
@@ -581,7 +581,7 @@ linters:
581
581
force-expect-to : true
582
582
583
583
# Best effort validation of async intervals (timeout and polling).
584
- # Ignored the suppress-async-assertion is true.
584
+ # Ignored the ` suppress-async-assertion` is true.
585
585
# Default: false
586
586
validate-async-intervals : true
587
587
@@ -597,7 +597,7 @@ linters:
597
597
# Presence of `default` case in switch statements satisfies exhaustiveness, if all members are not listed.
598
598
# Default: true
599
599
default-signifies-exhaustive : false
600
- # Include shared interfaces in the exhaustiviness check.
600
+ # Include shared interfaces in the exhaustiveness check.
601
601
# Default: false
602
602
include-shared-interfaces : true
603
603
@@ -619,10 +619,10 @@ linters:
619
619
# Search also for duplicated numbers.
620
620
# Default: false
621
621
numbers : true
622
- # Minimum value, only works with goconst.numbers
622
+ # Minimum value, only works with ` goconst.numbers`.
623
623
# Default: 3
624
624
min : 2
625
- # Maximum value, only works with goconst.numbers
625
+ # Maximum value, only works with ` goconst.numbers`.
626
626
# Default: 3
627
627
max : 2
628
628
# Ignore when constant is not used as function argument.
@@ -1095,7 +1095,7 @@ linters:
1095
1095
1096
1096
# Settings passed to gocritic.
1097
1097
# The settings key is the name of a supported gocritic checker.
1098
- # The list of supported checkers can be find in https://go-critic.com/overview.
1098
+ # The list of supported checkers can be found at https://go-critic.com/overview.
1099
1099
settings :
1100
1100
# Must be valid enabled check name.
1101
1101
captLocal :
@@ -1234,19 +1234,19 @@ linters:
1234
1234
# for example:
1235
1235
AUTHOR : .*@mycompany\.com
1236
1236
# The template used for checking.
1237
- # Put here copyright header template for source code files
1237
+ # Put here copyright header template for source code files.
1238
1238
# Note: {{ YEAR }} is a builtin value that returns the year relative to the current machine time.
1239
1239
# Default: ""
1240
1240
template : |-
1241
1241
{{ AUTHOR }} {{ COMPANY }} {{ YEAR }}
1242
1242
SPDX-License-Identifier: Apache-2.0
1243
-
1243
+
1244
1244
Licensed under the Apache License, Version 2.0 (the "License");
1245
1245
you may not use this file except in compliance with the License.
1246
1246
You may obtain a copy of the License at:
1247
-
1247
+
1248
1248
http://www.apache.org/licenses/LICENSE-2.0
1249
-
1249
+
1250
1250
Unless required by applicable law or agreed to in writing, software
1251
1251
distributed under the License is distributed on an "AS IS" BASIS,
1252
1252
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -1494,13 +1494,13 @@ linters:
1494
1494
# Regexp pattern to find potential directory traversal.
1495
1495
# Default: "http\\.Dir\\(\"\\/\"\\)|http\\.Dir\\('\\/'\\)"
1496
1496
pattern : " custom\\ .Dir\\ (\\ )"
1497
- # Maximum allowed permissions mode for os.Mkdir and os.MkdirAll
1497
+ # Maximum allowed permissions mode for os.Mkdir and os.MkdirAll.
1498
1498
# Default: "0750"
1499
1499
G301 : " 0750"
1500
- # Maximum allowed permissions mode for os.OpenFile and os.Chmod
1500
+ # Maximum allowed permissions mode for os.OpenFile and os.Chmod.
1501
1501
# Default: "0600"
1502
1502
G302 : " 0600"
1503
- # Maximum allowed permissions mode for os.WriteFile and ioutil.WriteFile
1503
+ # Maximum allowed permissions mode for os.WriteFile and ioutil.WriteFile.
1504
1504
# Default: "0600"
1505
1505
G306 : " 0600"
1506
1506
@@ -1536,7 +1536,7 @@ linters:
1536
1536
# Default: false
1537
1537
disable-all : true
1538
1538
# Enable analyzers by name.
1539
- # (in addition to default:
1539
+ # (In addition to default:
1540
1540
# appends, asmdecl, assign, atomic, bools, buildtag, cgocall, composites, copylocks, defers, directive, errorsas,
1541
1541
# framepointer, httpresponse, ifaceassert, loopclosure, lostcancel, nilfunc, printf, shift, sigchanyzer, slog,
1542
1542
# stdmethods, stringintconv, structtag, testinggoroutine, tests, timeformat, unmarshal, unreachable, unsafeptr,
@@ -1636,7 +1636,7 @@ linters:
1636
1636
# Default: false
1637
1637
enable-all : true
1638
1638
# Disable analyzers by name.
1639
- # (in addition to default
1639
+ # (In addition to default
1640
1640
# atomicalign, deepequalerrors, fieldalignment, findcall, nilness, reflectvaluecompare, shadow, sortslice,
1641
1641
# timeformat, unusedwrite
1642
1642
# ).
@@ -1703,16 +1703,16 @@ linters:
1703
1703
# Default: false
1704
1704
strict : true
1705
1705
unusedresult :
1706
- # Comma-separated list of functions whose results must be used
1707
- # (in addition to default:
1706
+ # Comma-separated list of functions whose results must be used.
1707
+ # (In addition to default:
1708
1708
# context.WithCancel, context.WithDeadline, context.WithTimeout, context.WithValue, errors.New, fmt.Errorf,
1709
1709
# fmt.Sprint, fmt.Sprintf, sort.Reverse
1710
1710
# ).
1711
1711
# Default: []
1712
1712
funcs :
1713
1713
- pkg.MyFunc
1714
- # Comma-separated list of names of methods of type func() string whose results must be used
1715
- # (in addition to default Error,String)
1714
+ # Comma-separated list of names of methods of type func() string whose results must be used.
1715
+ # (In addition to default Error,String).
1716
1716
# Default: []
1717
1717
stringmethods :
1718
1718
- MyMethod
@@ -1778,7 +1778,7 @@ linters:
1778
1778
alias : autoscalingv1alpha1
1779
1779
# You can specify the package path by regular expression,
1780
1780
# and alias by regular expression expansion syntax like below.
1781
- # see https://github.com/julz/importas#use-regular-expression for details
1781
+ # See https://github.com/julz/importas#use-regular-expression for details.
1782
1782
- pkg : knative.dev/serving/pkg/apis/(\w+)/(v[\w\d]+)
1783
1783
alias : $1$2
1784
1784
# An explicit empty alias can be used to ensure no aliases are used for a package.
@@ -1917,14 +1917,14 @@ linters:
1917
1917
- assign
1918
1918
# List of numbers to exclude from analysis.
1919
1919
# The numbers should be written as string.
1920
- # Values always ignored: "1", "1.0", "0" and "0.0"
1920
+ # Values always ignored: "1", "1.0", "0" and "0.0".
1921
1921
# Default: []
1922
1922
ignored-numbers :
1923
1923
- ' 0666'
1924
1924
- ' 0755'
1925
1925
- ' 42'
1926
1926
# List of file patterns to exclude from analysis.
1927
- # Values always ignored: `.+_test.go`
1927
+ # Values always ignored: `.+_test.go`.
1928
1928
# Default: []
1929
1929
ignored-files :
1930
1930
- ' magic1_.+\.go$'
@@ -1979,7 +1979,7 @@ linters:
1979
1979
- unsafeptr
1980
1980
1981
1981
nlreturn :
1982
- # Size of the block (including return statement that is still "OK")
1982
+ # Size of the block (including return statement that is still "OK"),
1983
1983
# so no return split required.
1984
1984
# Default: 1
1985
1985
block-size : 2
@@ -2681,7 +2681,7 @@ linters:
2681
2681
exclude : [""]
2682
2682
2683
2683
rowserrcheck :
2684
- # database/sql is always checked
2684
+ # database/sql is always checked.
2685
2685
# Default: []
2686
2686
packages :
2687
2687
- github.com/jmoiron/sqlx
@@ -3267,7 +3267,7 @@ linters:
3267
3267
# Align and sort can be used together or separately.
3268
3268
#
3269
3269
# Whether enable align. If true, the struct tags will be aligned.
3270
- # e .g.:
3270
+ # E .g.:
3271
3271
# type FooBar struct {
3272
3272
# Bar string `json:"bar" validate:"required"`
3273
3273
# FooFoo int8 `json:"foo_foo" validate:"required"`
@@ -3281,7 +3281,7 @@ linters:
3281
3281
align : false
3282
3282
# Whether enable tags sort.
3283
3283
# If true, the tags will be sorted by name in ascending order.
3284
- # e .g.: `xml:"bar" json:"bar" validate:"required"` -> `json:"bar" validate:"required" xml:"bar"`
3284
+ # E .g.: `xml:"bar" json:"bar" validate:"required"` -> `json:"bar" validate:"required" xml:"bar"`.
3285
3285
# Default: true
3286
3286
sort : false
3287
3287
# Specify the order of tags, the other tags will be sorted by name.
@@ -3947,7 +3947,7 @@ formatters:
3947
3947
gci :
3948
3948
# Section configuration to compare against.
3949
3949
# Section names are case-insensitive and may contain parameters in ().
3950
- # The default order of sections is `standard > default > custom > blank > dot > alias > localmodule`,
3950
+ # The default order of sections is `standard > default > custom > blank > dot > alias > localmodule`.
3951
3951
# If `custom-order` is `true`, it follows the order of `sections` option.
3952
3952
# Default: ["standard", "default"]
3953
3953
sections :
0 commit comments