diff --git a/docs/.gitignore b/docs/.gitignore index c92be3dc739b..6a4a2d4e79b3 100644 --- a/docs/.gitignore +++ b/docs/.gitignore @@ -1,9 +1,15 @@ -# Hugo files +### Hugo files .hugo_build.lock public/ resources/ -# Generated files +### Generated files + +# Generated by /scripts/copy_jsonschema /static/jsonschema/ + +# Generated by /scripts/expand_templates data/version.json +data/formatter_settings.json +data/linter_settings.json .tmp/ diff --git a/docs/data/formatter_settings.json b/docs/data/formatter_settings.json deleted file mode 100644 index 04257b997dc6..000000000000 --- a/docs/data/formatter_settings.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "gci": "formatters:\n settings:\n gci:\n # Section configuration to compare against.\n # Section names are case-insensitive and may contain parameters in ().\n # The default order of sections is `standard \u003e default \u003e custom \u003e blank \u003e dot \u003e alias \u003e localmodule`.\n # If `custom-order` is `true`, it follows the order of `sections` option.\n # Default: [\"standard\", \"default\"]\n sections:\n - standard # Standard section: captures all standard packages.\n - default # Default section: contains all imports that could not be matched to another section type.\n - prefix(github.com/org/project) # Custom section: groups all imports with the specified Prefix.\n - blank # Blank section: contains all blank imports. This section is not present unless explicitly enabled.\n - dot # Dot section: contains all dot imports. This section is not present unless explicitly enabled.\n - alias # Alias section: contains all alias imports. This section is not present unless explicitly enabled.\n - localmodule # Local module section: contains all local packages. This section is not present unless explicitly enabled.\n # Checks that no inline comments are present.\n # Default: false\n no-inline-comments: true\n # Checks that no prefix comments (comment lines above an import) are present.\n # Default: false\n no-prefix-comments: true\n # Enable custom order of sections.\n # If `true`, make the section order the same as the order of `sections`.\n # Default: false\n custom-order: true\n # Drops lexical ordering for custom sections.\n # Default: false\n no-lex-order: true\n", - "gofmt": "formatters:\n settings:\n gofmt:\n # Simplify code: gofmt with `-s` option.\n # Default: true\n simplify: false\n # Apply the rewrite rules to the source before reformatting.\n # https://pkg.go.dev/cmd/gofmt\n # Default: []\n rewrite-rules:\n - pattern: 'interface{}'\n replacement: 'any'\n - pattern: 'a[b:len(a)]'\n replacement: 'a[b:]'\n", - "gofumpt": "formatters:\n settings:\n gofumpt:\n # Module path which contains the source code being formatted.\n # Default: \"\"\n module-path: github.com/org/project\n # Choose whether to use the extra rules.\n # Default: false\n extra-rules: true\n", - "goimports": "formatters:\n settings:\n goimports:\n # A list of prefixes, which, if set, checks import paths\n # with the given prefixes are grouped after 3rd-party packages.\n # Default: []\n local-prefixes:\n - github.com/org/project\n", - "golines": "formatters:\n settings:\n golines:\n # Target maximum line length.\n # Default: 100\n max-len: 200\n # Length of a tabulation.\n # Default: 4\n tab-len: 8\n # Shorten single-line comments.\n # Default: false\n shorten-comments: true\n # Default: true\n reformat-tags: false\n # Split chained methods on the dots as opposed to the arguments.\n # Default: true\n chain-split-dots: false\n" -} diff --git a/docs/data/linter_settings.json b/docs/data/linter_settings.json deleted file mode 100644 index 76159eb12a46..000000000000 --- a/docs/data/linter_settings.json +++ /dev/null @@ -1,81 +0,0 @@ -{ - "asasalint": "linters:\n settings:\n asasalint:\n # To specify a set of function names to exclude.\n # The values are merged with the builtin exclusions.\n # The builtin exclusions can be disabled by setting `use-builtin-exclusions` to `false`.\n # Default: [\"^(fmt|log|logger|t|)\\.(Print|Fprint|Sprint|Fatal|Panic|Error|Warn|Warning|Info|Debug|Log)(|f|ln)$\"]\n exclude:\n - Append\n - \\.Wrapf\n # To enable/disable the asasalint builtin exclusions of function names.\n # See the default value of `exclude` to get the builtin exclusions.\n # Default: true\n use-builtin-exclusions: false\n", - "bidichk": "linters:\n settings:\n bidichk:\n # The following configurations check for all mentioned invisible Unicode runes.\n # All runes are enabled by default.\n left-to-right-embedding: false\n right-to-left-embedding: false\n pop-directional-formatting: false\n left-to-right-override: false\n right-to-left-override: false\n left-to-right-isolate: false\n right-to-left-isolate: false\n first-strong-isolate: false\n pop-directional-isolate: false\n", - "copyloopvar": "linters:\n settings:\n copyloopvar:\n # Check all assigning the loop variable to another variable.\n # Default: false\n check-alias: true\n", - "cyclop": "linters:\n settings:\n cyclop:\n # The maximal code complexity to report.\n # Default: 10\n max-complexity: 10\n # The maximal average package complexity.\n # If it's higher than 0.0 (float) the check is enabled.\n # Default: 0.0\n package-average: 0.5\n", - "decorder": "linters:\n settings:\n decorder:\n # Required order of `type`, `const`, `var` and `func` declarations inside a file.\n # Default: types before constants before variables before functions.\n dec-order:\n - type\n - const\n - var\n - func\n # If true, underscore vars (vars with \"_\" as the name) will be ignored at all checks.\n # Default: false (underscore vars are not ignored)\n ignore-underscore-vars: false\n # If true, order of declarations is not checked at all.\n # Default: true (disabled)\n disable-dec-order-check: false\n # If true, `init` func can be anywhere in file (does not have to be declared before all other functions).\n # Default: true (disabled)\n disable-init-func-first-check: false\n # If true, multiple global `type`, `const` and `var` declarations are allowed.\n # Default: true (disabled)\n disable-dec-num-check: false\n # If true, type declarations will be ignored for dec num check.\n # Default: false (type statements are not ignored)\n disable-type-dec-num-check: false\n # If true, const declarations will be ignored for dec num check.\n # Default: false (const statements are not ignored)\n disable-const-dec-num-check: false\n # If true, var declarations will be ignored for dec num check.\n # Default: false (var statements are not ignored)\n disable-var-dec-num-check: false\n", - "depguard": "linters:\n settings:\n depguard:\n # Rules to apply.\n #\n # Variables:\n # - File Variables\n # Use an exclamation mark `!` to negate a variable.\n # Example: `!$test` matches any file that is not a go test file.\n #\n # `$all` - matches all go files\n # `$test` - matches all go test files\n #\n # - Package Variables\n #\n # `$gostd` - matches all of go's standard library (Pulled from `GOROOT`)\n #\n # Default (applies if no custom rules are defined): Only allow $gostd in all files.\n rules:\n # Name of a rule.\n main:\n # Defines package matching behavior. Available modes:\n # - `original`: allowed if it doesn't match the deny list and either matches the allow list or the allow list is empty.\n # - `strict`: allowed only if it matches the allow list and either doesn't match the deny list or the allow rule is more specific (longer) than the deny rule.\n # - `lax`: allowed if it doesn't match the deny list or the allow rule is more specific (longer) than the deny rule.\n # Default: \"original\"\n list-mode: lax\n # List of file globs that will match this list of settings to compare against.\n # By default, if a path is relative, it is relative to the directory where the golangci-lint command is executed.\n # The placeholder '${base-path}' is substituted with a path relative to the mode defined with `run.relative-path-mode`.\n # The placeholder '${config-path}' is substituted with a path relative to the configuration file.\n # Default: $all\n files:\n - \"!**/*_a _file.go\"\n # List of allowed packages.\n # Entries can be a variable (starting with $), a string prefix, or an exact match (if ending with $).\n # Default: []\n allow:\n - $gostd\n - github.com/OpenPeeDeeP\n # List of packages that are not allowed.\n # Entries can be a variable (starting with $), a string prefix, or an exact match (if ending with $).\n # Default: []\n deny:\n - pkg: \"math/rand$\"\n desc: use math/rand/v2\n - pkg: \"github.com/sirupsen/logrus\"\n desc: not allowed\n - pkg: \"github.com/pkg/errors\"\n desc: Should be replaced by standard lib errors package\n", - "dogsled": "linters:\n settings:\n dogsled:\n # Checks assignments with too many blank identifiers.\n # Default: 2\n max-blank-identifiers: 3\n", - "dupl": "linters:\n settings:\n dupl:\n # Tokens count to trigger issue.\n # Default: 150\n threshold: 100\n", - "dupword": "linters:\n settings:\n dupword:\n # Keywords for detecting duplicate words.\n # If this list is not empty, only the words defined in this list will be detected.\n # Default: []\n keywords:\n - \"the\"\n - \"and\"\n - \"a\"\n # Keywords used to ignore detection.\n # Default: []\n ignore:\n - \"0C0C\"\n", - "embeddedstructfieldcheck": "linters:\n settings:\n embeddedstructfieldcheck:\n # Checks that sync.Mutex and sync.RWMutex are not used as embedded fields.\n # Default: false\n forbid-mutex: true\n", - "errcheck": "linters:\n settings:\n errcheck:\n # Report about not checking of errors in type assertions: `a := b.(MyStruct)`.\n # Such cases aren't reported by default.\n # Default: false\n check-type-assertions: true\n # report about assignment of errors to blank identifier: `num, _ := strconv.Atoi(numStr)`.\n # Such cases aren't reported by default.\n # Default: false\n check-blank: true\n # To disable the errcheck built-in exclude list.\n # See `-excludeonly` option in https://github.com/kisielk/errcheck#excluding-functions for details.\n # Default: false\n disable-default-exclusions: true\n # List of functions to exclude from checking, where each entry is a single function to exclude.\n # See https://github.com/kisielk/errcheck#excluding-functions for details.\n exclude-functions:\n - io/ioutil.ReadFile\n - io.Copy(*bytes.Buffer)\n - io.Copy(os.Stdout)\n # Display function signature instead of selector.\n # Default: false\n verbose: true\n", - "errchkjson": "linters:\n settings:\n errchkjson:\n # With check-error-free-encoding set to true, errchkjson does warn about errors\n # from json encoding functions that are safe to be ignored,\n # because they are not possible to happen.\n #\n # if check-error-free-encoding is set to true and errcheck linter is enabled,\n # it is recommended to add the following exceptions to prevent from false positives:\n #\n # linters:\n # settings:\n # errcheck:\n # exclude-functions:\n # - encoding/json.Marshal\n # - encoding/json.MarshalIndent\n #\n # Default: false\n check-error-free-encoding: true\n # Issue on struct encoding that doesn't have exported fields.\n # Default: false\n report-no-exported: false\n", - "errorlint": "linters:\n settings:\n errorlint:\n # Check whether fmt.Errorf uses the %w verb for formatting errors.\n # See the https://github.com/polyfloyd/go-errorlint for caveats.\n # Default: true\n errorf: false\n # Permit more than 1 %w verb, valid per Go 1.20 (requires `errorf: true`).\n # Default: true\n errorf-multi: false\n # Check for plain type assertions and type switches.\n # Default: true\n asserts: false\n # Check for plain error comparisons.\n # Default: true\n comparison: false\n # Allowed errors.\n # Default: []\n allowed-errors:\n - err: \"io.EOF\"\n fun: \"example.com/pkg.Read\"\n # Allowed error \"wildcards\".\n # Default: []\n allowed-errors-wildcard:\n - err: \"example.com/pkg.ErrMagic\"\n fun: \"example.com/pkg.Magic\"\n", - "exhaustive": "linters:\n settings:\n exhaustive:\n # Program elements to check for exhaustiveness.\n # Default: [ switch ]\n check:\n - switch\n - map\n # Presence of \"default\" case in switch statements satisfies exhaustiveness,\n # even if all enum members are not listed.\n # Default: false\n default-signifies-exhaustive: true\n # Enum members matching the supplied regex do not have to be listed in\n # switch statements to satisfy exhaustiveness.\n # Default: \"\"\n ignore-enum-members: \"Example.+\"\n # Enum types matching the supplied regex do not have to be listed in\n # switch statements to satisfy exhaustiveness.\n # Default: \"\"\n ignore-enum-types: \"Example.+\"\n # Consider enums only in package scopes, not in inner scopes.\n # Default: false\n package-scope-only: true\n # Only run exhaustive check on switches with \"//exhaustive:enforce\" comment.\n # Default: false\n explicit-exhaustive-switch: true\n # Only run exhaustive check on map literals with \"//exhaustive:enforce\" comment.\n # Default: false\n explicit-exhaustive-map: true\n # Switch statement requires default case even if exhaustive.\n # Default: false\n default-case-required: true\n", - "exhaustruct": "linters:\n settings:\n exhaustruct:\n # List of regular expressions to match struct packages and their names.\n # Regular expressions must match complete canonical struct package/name/structname.\n # If this list is empty, all structs are tested.\n # Default: []\n include:\n - '.+\\.Test'\n - 'example\\.com/package\\.ExampleStruct[\\d]{1,2}'\n # List of regular expressions to exclude struct packages and their names from checks.\n # Regular expressions must match complete canonical struct package/name/structname.\n # Default: []\n exclude:\n - '.+/cobra\\.Command$'\n", - "fatcontext": "linters:\n settings:\n fatcontext:\n # Check for potential fat contexts in struct pointers.\n # May generate false positives.\n # Default: false\n check-struct-pointers: true\n", - "forbidigo": "linters:\n settings:\n forbidigo:\n # Forbid the following identifiers (list of regexp).\n # Default: [\"^(fmt\\\\.Print(|f|ln)|print|println)$\"]\n forbid:\n # Built-in bootstrapping functions.\n - pattern: ^print(ln)?$\n # Optional message that gets included in error reports.\n - pattern: ^fmt\\.Print.*$\n msg: Do not commit print statements.\n # Alternatively, put messages at the end of the regex, surrounded by `(# )?`.\n # Escape any special characters. Those messages get included in error reports.\n - pattern: 'fmt\\.Print.*(# Do not commit print statements\\.)?'\n # Forbid spew Dump, whether it is called as function or method.\n # Depends on analyze-types below.\n - pattern: ^spew\\.(ConfigState\\.)?Dump$\n # The package name might be ambiguous.\n # The full import path can be used as additional criteria.\n # Depends on analyze-types below.\n - pattern: ^v1.Dump$\n pkg: ^example.com/pkg/api/v1$\n # Exclude godoc examples from forbidigo checks.\n # Default: true\n exclude-godoc-examples: false\n # Instead of matching the literal source code,\n # use type information to replace expressions with strings that contain the package name\n # and (for methods and fields) the type name.\n # This makes it possible to handle import renaming and forbid struct fields and methods.\n # Default: false\n analyze-types: true\n", - "funcorder": "linters:\n settings:\n funcorder:\n # Checks that constructors are placed after the structure declaration.\n # Default: true\n constructor: false\n # Checks if the exported methods of a structure are placed before the non-exported ones.\n # Default: true\n struct-method: false\n # Checks if the constructors and/or structure methods are sorted alphabetically.\n # Default: false\n alphabetical: true\n", - "funlen": "linters:\n settings:\n funlen:\n # Checks the number of lines in a function.\n # If lower than 0, disable the check.\n # Default: 60\n lines: -1\n # Checks the number of statements in a function.\n # If lower than 0, disable the check.\n # Default: 40\n statements: -1\n # Ignore comments when counting lines.\n # Default: true\n ignore-comments: false\n", - "ginkgolinter": "linters:\n settings:\n ginkgolinter:\n # Suppress the wrong length assertion warning.\n # Default: false\n suppress-len-assertion: true\n # Suppress the wrong nil assertion warning.\n # Default: false\n suppress-nil-assertion: true\n # Suppress the wrong error assertion warning.\n # Default: false\n suppress-err-assertion: true\n # Suppress the wrong comparison assertion warning.\n # Default: false\n suppress-compare-assertion: true\n # Suppress the function all in async assertion warning.\n # Default: false\n suppress-async-assertion: true\n # Suppress warning for comparing values from different types, like `int32` and `uint32`.\n # Default: false\n suppress-type-compare-assertion: true\n # Trigger warning for ginkgo focus containers like `FDescribe`, `FContext`, `FWhen` or `FIt`.\n # Default: false\n forbid-focus-container: true\n # Don't trigger warnings for HaveLen(0)\n # Default: false\n allow-havelen-zero: true\n # Force using `Expect` with `To`, `ToNot` or `NotTo`.\n # Reject using `Expect` with `Should` or `ShouldNot`.\n # Default: false\n force-expect-to: true\n # Best effort validation of async intervals (timeout and polling).\n # Ignored the `suppress-async-assertion` is true.\n # Default: false\n validate-async-intervals: true\n # Trigger a warning for variable assignments in ginkgo containers like `Describe`, `Context` and `When`, instead of in `BeforeEach()`.\n # Default: false\n forbid-spec-pollution: true\n # Force using the Succeed matcher for error functions, and the HaveOccurred matcher for non-function error values.\n # Default: false\n force-succeed: true\n # Force adding assertion descriptions to gomega matchers.\n # Default: false\n force-assertion-description: true\n", - "gochecksumtype": "linters:\n settings:\n gochecksumtype:\n # Presence of `default` case in switch statements satisfies exhaustiveness, if all members are not listed.\n # Default: true\n default-signifies-exhaustive: false\n # Include shared interfaces in the exhaustiveness check.\n # Default: false\n include-shared-interfaces: true\n", - "gocognit": "linters:\n settings:\n gocognit:\n # Minimal code complexity to report.\n # Default: 30 (but we recommend 10-20)\n min-complexity: 10\n", - "goconst": "linters:\n settings:\n goconst:\n # Minimal length of string constant.\n # Default: 3\n min-len: 2\n # Minimum occurrences of constant string count to trigger issue.\n # Default: 3\n min-occurrences: 2\n # Look for existing constants matching the values.\n # Default: true\n match-constant: false\n # Search also for duplicated numbers.\n # Default: false\n numbers: true\n # Minimum value, only works with `goconst.numbers`.\n # Default: 3\n min: 2\n # Maximum value, only works with `goconst.numbers`.\n # Default: 3\n max: 2\n # Ignore when constant is not used as function argument.\n # Default: true\n ignore-calls: false\n # Exclude strings matching the given regular expression.\n # Default: \"\"\n ignore-string-values:\n - 'foo.+'\n # Detects constants with identical values.\n # Default: false\n find-duplicates: true\n # Evaluates of constant expressions like Prefix + \"suffix\".\n # Default: false\n eval-const-expressions: true\n", - "gocritic": "linters:\n settings:\n gocritic:\n # Disable all checks.\n # Default: false\n disable-all: true\n # Which checks should be enabled in addition to default checks; can't be combined with 'disabled-checks'.\n # By default, list of stable checks is used (https://go-critic.com/overview#checks-overview):\n # appendAssign, argOrder, assignOp, badCall, badCond, captLocal, caseOrder, codegenComment, commentFormatting,\n # defaultCaseOrder, deprecatedComment, dupArg, dupBranchBody, dupCase, dupSubExpr, elseif, exitAfterDefer,\n # flagDeref, flagName, ifElseChain, mapKey, newDeref, offBy1, regexpMust, singleCaseSwitch, sloppyLen,\n # sloppyTypeAssert, switchTrue, typeSwitchVar, underef, unlambda, unslice, valSwap, wrapperFunc\n # To see which checks are enabled run `GL_DEBUG=gocritic golangci-lint run --enable=gocritic`.\n enabled-checks:\n # Detects suspicious append result assignments.\n # https://go-critic.com/overview.html#appendassign\n - appendAssign\n # Detects `append` chains to the same slice that can be done in a single `append` call.\n # https://go-critic.com/overview.html#appendcombine\n - appendCombine\n # Detects suspicious arguments order.\n # https://go-critic.com/overview.html#argorder\n - argOrder\n # Detects assignments that can be simplified by using assignment operators.\n # https://go-critic.com/overview.html#assignop\n - assignOp\n # Detects suspicious function calls.\n # https://go-critic.com/overview.html#badcall\n - badCall\n # Detects suspicious condition expressions.\n # https://go-critic.com/overview.html#badcond\n - badCond\n # Detects suspicious mutex lock/unlock operations.\n # https://go-critic.com/overview.html#badlock\n - badLock\n # Detects suspicious regexp patterns.\n # https://go-critic.com/overview.html#badregexp\n - badRegexp\n # Detects bad usage of sort package.\n # https://go-critic.com/overview.html#badsorting\n - badSorting\n # Detects bad usage of sync.OnceFunc.\n # https://go-critic.com/overview.html#badsynconcefunc\n - badSyncOnceFunc\n # Detects bool expressions that can be simplified.\n # https://go-critic.com/overview.html#boolexprsimplify\n - boolExprSimplify\n # Detects when predeclared identifiers are shadowed in assignments.\n # https://go-critic.com/overview.html#builtinshadow\n - builtinShadow\n # Detects top-level declarations that shadow the predeclared identifiers.\n # https://go-critic.com/overview.html#builtinshadowdecl\n - builtinShadowDecl\n # Detects capitalized names for local variables.\n # https://go-critic.com/overview.html#captlocal\n - captLocal\n # Detects erroneous case order inside switch statements.\n # https://go-critic.com/overview.html#caseorder\n - caseOrder\n # Detects malformed 'code generated' file comments.\n # https://go-critic.com/overview.html#codegencomment\n - codegenComment\n # Detects comments with non-idiomatic formatting.\n # https://go-critic.com/overview.html#commentformatting\n - commentFormatting\n # Detects commented-out code inside function bodies.\n # https://go-critic.com/overview.html#commentedoutcode\n - commentedOutCode\n # Detects commented-out imports.\n # https://go-critic.com/overview.html#commentedoutimport\n - commentedOutImport\n # Detects when default case in switch isn't on 1st or last position.\n # https://go-critic.com/overview.html#defaultcaseorder\n - defaultCaseOrder\n # Detects loops inside functions that use defer.\n # https://go-critic.com/overview.html#deferinloop\n - deferInLoop\n # Detects deferred function literals that can be simplified.\n # https://go-critic.com/overview.html#deferunlambda\n - deferUnlambda\n # Detects malformed 'deprecated' doc-comments.\n # https://go-critic.com/overview.html#deprecatedcomment\n - deprecatedComment\n # Detects comments that silence go lint complaints about doc-comment.\n # https://go-critic.com/overview.html#docstub\n - docStub\n # Detects suspicious duplicated arguments.\n # https://go-critic.com/overview.html#duparg\n - dupArg\n # Detects duplicated branch bodies inside conditional statements.\n # https://go-critic.com/overview.html#dupbranchbody\n - dupBranchBody\n # Detects duplicated case clauses inside switch or select statements.\n # https://go-critic.com/overview.html#dupcase\n - dupCase\n # Detects multiple imports of the same package under different aliases.\n # https://go-critic.com/overview.html#dupimport\n - dupImport\n # Detects suspicious duplicated sub-expressions.\n # https://go-critic.com/overview.html#dupsubexpr\n - dupSubExpr\n # Detects suspicious formatting strings usage.\n # https://go-critic.com/overview.html#dynamicfmtstring\n - dynamicFmtString\n # Detects else with nested if statement that can be replaced with else-if.\n # https://go-critic.com/overview.html#elseif\n - elseif\n # Detects suspicious empty declarations blocks.\n # https://go-critic.com/overview.html#emptydecl\n - emptyDecl\n # Detects fallthrough that can be avoided by using multi case values.\n # https://go-critic.com/overview.html#emptyfallthrough\n - emptyFallthrough\n # Detects empty string checks that can be written more idiomatically.\n # https://go-critic.com/overview.html#emptystringtest\n - emptyStringTest\n # Detects unoptimal strings/bytes case-insensitive comparison.\n # https://go-critic.com/overview.html#equalfold\n - equalFold\n # Detects unwanted dependencies on the evaluation order.\n # https://go-critic.com/overview.html#evalorder\n - evalOrder\n # Detects calls to exit/fatal inside functions that use defer.\n # https://go-critic.com/overview.html#exitafterdefer\n - exitAfterDefer\n # Detects exposed methods from sync.Mutex and sync.RWMutex.\n # https://go-critic.com/overview.html#exposedsyncmutex\n - exposedSyncMutex\n # Detects suspicious reassignment of error from another package.\n # https://go-critic.com/overview.html#externalerrorreassign\n - externalErrorReassign\n # Detects problems in filepath.Join() function calls.\n # https://go-critic.com/overview.html#filepathjoin\n - filepathJoin\n # Detects immediate dereferencing of `flag` package pointers.\n # https://go-critic.com/overview.html#flagderef\n - flagDeref\n # Detects suspicious flag names.\n # https://go-critic.com/overview.html#flagname\n - flagName\n # Detects hex literals that have mixed case letter digits.\n # https://go-critic.com/overview.html#hexliteral\n - hexLiteral\n # Detects nil usages in http.NewRequest calls, suggesting http.NoBody as an alternative.\n # https://go-critic.com/overview.html#httpnobody\n - httpNoBody\n # Detects params that incur excessive amount of copying.\n # https://go-critic.com/overview.html#hugeparam\n - hugeParam\n # Detects repeated if-else statements and suggests to replace them with switch statement.\n # https://go-critic.com/overview.html#ifelsechain\n - ifElseChain\n # Detects when imported package names shadowed in the assignments.\n # https://go-critic.com/overview.html#importshadow\n - importShadow\n # Detects strings.Index calls that may cause unwanted allocs.\n # https://go-critic.com/overview.html#indexalloc\n - indexAlloc\n # Detects non-assignment statements inside if/switch init clause.\n # https://go-critic.com/overview.html#initclause\n - initClause\n # Detects suspicious map literal keys.\n # https://go-critic.com/overview.html#mapkey\n - mapKey\n # Detects method expression call that can be replaced with a method call.\n # https://go-critic.com/overview.html#methodexprcall\n - methodExprCall\n # Finds where nesting level could be reduced.\n # https://go-critic.com/overview.html#nestingreduce\n - nestingReduce\n # Detects immediate dereferencing of `new` expressions.\n # https://go-critic.com/overview.html#newderef\n - newDeref\n # Detects return statements those results evaluate to nil.\n # https://go-critic.com/overview.html#nilvalreturn\n - nilValReturn\n # Detects old-style octal literals.\n # https://go-critic.com/overview.html#octalliteral\n - octalLiteral\n # Detects various off-by-one kind of errors.\n # https://go-critic.com/overview.html#offby1\n - offBy1\n # Detects if function parameters could be combined by type and suggest the way to do it.\n # https://go-critic.com/overview.html#paramtypecombine\n - paramTypeCombine\n # Detects expressions like []rune(s)[0] that may cause unwanted rune slice allocation.\n # https://go-critic.com/overview.html#preferdecoderune\n - preferDecodeRune\n # Detects concatenation with os.PathSeparator which can be replaced with filepath.Join.\n # https://go-critic.com/overview.html#preferfilepathjoin\n - preferFilepathJoin\n # Detects fmt.Sprint(f/ln) calls which can be replaced with fmt.Fprint(f/ln).\n # https://go-critic.com/overview.html#preferfprint\n - preferFprint\n # Detects w.Write or io.WriteString calls which can be replaced with w.WriteString.\n # https://go-critic.com/overview.html#preferstringwriter\n - preferStringWriter\n # Detects WriteRune calls with rune literal argument that is single byte and reports to use WriteByte instead.\n # https://go-critic.com/overview.html#preferwritebyte\n - preferWriteByte\n # Detects input and output parameters that have a type of pointer to referential type.\n # https://go-critic.com/overview.html#ptrtorefparam\n - ptrToRefParam\n # Detects append all its data while range it.\n # https://go-critic.com/overview.html#rangeappendall\n - rangeAppendAll\n # Detects expensive copies of `for` loop range expressions.\n # https://go-critic.com/overview.html#rangeexprcopy\n - rangeExprCopy\n # Detects loops that copy big objects during each iteration.\n # https://go-critic.com/overview.html#rangevalcopy\n - rangeValCopy\n # Detects redundant fmt.Sprint calls.\n # https://go-critic.com/overview.html#redundantsprint\n - redundantSprint\n # Detects `regexp.Compile*` that can be replaced with `regexp.MustCompile*`.\n # https://go-critic.com/overview.html#regexpmust\n - regexpMust\n # Detects suspicious regexp patterns.\n # https://go-critic.com/overview.html#regexppattern\n - regexpPattern\n # Detects regexp patterns that can be simplified.\n # https://go-critic.com/overview.html#regexpsimplify\n - regexpSimplify\n # Detects suspicious http.Error call without following return.\n # https://go-critic.com/overview.html#returnafterhttperror\n - returnAfterHttpError\n # Runs user-defined rules using ruleguard linter.\n # https://go-critic.com/overview.html#ruleguard\n - ruleguard\n # Detects switch statements that could be better written as if statement.\n # https://go-critic.com/overview.html#singlecaseswitch\n - singleCaseSwitch\n # Detects slice clear loops, suggests an idiom that is recognized by the Go compiler.\n # https://go-critic.com/overview.html#sliceclear\n - sliceClear\n # Detects usage of `len` when result is obvious or doesn't make sense.\n # https://go-critic.com/overview.html#sloppylen\n - sloppyLen\n # Detects suspicious/confusing re-assignments.\n # https://go-critic.com/overview.html#sloppyreassign\n - sloppyReassign\n # Detects redundant type assertions.\n # https://go-critic.com/overview.html#sloppytypeassert\n - sloppyTypeAssert\n # Detects suspicious sort.Slice calls.\n # https://go-critic.com/overview.html#sortslice\n - sortSlice\n # Detects \"%s\" formatting directives that can be replaced with %q.\n # https://go-critic.com/overview.html#sprintfquotedstring\n - sprintfQuotedString\n # Detects issue in Query() and Exec() calls.\n # https://go-critic.com/overview.html#sqlquery\n - sqlQuery\n # Detects string concat operations that can be simplified.\n # https://go-critic.com/overview.html#stringconcatsimplify\n - stringConcatSimplify\n # Detects redundant conversions between string and []byte.\n # https://go-critic.com/overview.html#stringxbytes\n - stringXbytes\n # Detects strings.Compare usage.\n # https://go-critic.com/overview.html#stringscompare\n - stringsCompare\n # Detects switch-over-bool statements that use explicit `true` tag value.\n # https://go-critic.com/overview.html#switchtrue\n - switchTrue\n # Detects sync.Map load+delete operations that can be replaced with LoadAndDelete.\n # https://go-critic.com/overview.html#syncmaploadanddelete\n - syncMapLoadAndDelete\n # Detects manual conversion to milli- or microseconds.\n # https://go-critic.com/overview.html#timeexprsimplify\n - timeExprSimplify\n # Detects TODO comments without detail/assignee.\n # https://go-critic.com/overview.html#todocommentwithoutdetail\n - todoCommentWithoutDetail\n # Detects function with too many results.\n # https://go-critic.com/overview.html#toomanyresultschecker\n - tooManyResultsChecker\n # Detects potential truncation issues when comparing ints of different sizes.\n # https://go-critic.com/overview.html#truncatecmp\n - truncateCmp\n # Detects repeated type assertions and suggests to replace them with type switch statement.\n # https://go-critic.com/overview.html#typeassertchain\n - typeAssertChain\n # Detects method declarations preceding the type definition itself.\n # https://go-critic.com/overview.html#typedeffirst\n - typeDefFirst\n # Detects type switches that can benefit from type guard clause with variable.\n # https://go-critic.com/overview.html#typeswitchvar\n - typeSwitchVar\n # Detects unneeded parenthesis inside type expressions and suggests to remove them.\n # https://go-critic.com/overview.html#typeunparen\n - typeUnparen\n # Detects unchecked errors in if statements.\n # https://go-critic.com/overview.html#uncheckedinlineerr\n - uncheckedInlineErr\n # Detects dereference expressions that can be omitted.\n # https://go-critic.com/overview.html#underef\n - underef\n # Detects redundant statement labels.\n # https://go-critic.com/overview.html#unlabelstmt\n - unlabelStmt\n # Detects function literals that can be simplified.\n # https://go-critic.com/overview.html#unlambda\n - unlambda\n # Detects unnamed results that may benefit from names.\n # https://go-critic.com/overview.html#unnamedresult\n - unnamedResult\n # Detects unnecessary braced statement blocks.\n # https://go-critic.com/overview.html#unnecessaryblock\n - unnecessaryBlock\n # Detects redundantly deferred calls.\n # https://go-critic.com/overview.html#unnecessarydefer\n - unnecessaryDefer\n # Detects slice expressions that can be simplified to sliced expression itself.\n # https://go-critic.com/overview.html#unslice\n - unslice\n # Detects value swapping code that are not using parallel assignment.\n # https://go-critic.com/overview.html#valswap\n - valSwap\n # Detects conditions that are unsafe due to not being exhaustive.\n # https://go-critic.com/overview.html#weakcond\n - weakCond\n # Ensures that `//nolint` comments include an explanation.\n # https://go-critic.com/overview.html#whynolint\n - whyNoLint\n # Detects function calls that can be replaced with convenience wrappers.\n # https://go-critic.com/overview.html#wrapperfunc\n - wrapperFunc\n # Detects Yoda style expressions and suggests to replace them.\n # https://go-critic.com/overview.html#yodastyleexpr\n - yodaStyleExpr\n # Enable all checks.\n # Default: false\n enable-all: true\n # Which checks should be disabled; can't be combined with 'enabled-checks'.\n # Default: []\n disabled-checks:\n - appendAssign\n - appendCombine\n - argOrder\n - assignOp\n - badCall\n - badCond\n - badLock\n - badRegexp\n - badSorting\n - badSyncOnceFunc\n - boolExprSimplify\n - builtinShadow\n - builtinShadowDecl\n - captLocal\n - caseOrder\n - codegenComment\n - commentFormatting\n - commentedOutCode\n - commentedOutImport\n - defaultCaseOrder\n - deferInLoop\n - deferUnlambda\n - deprecatedComment\n - docStub\n - dupArg\n - dupBranchBody\n - dupCase\n - dupImport\n - dupSubExpr\n - dynamicFmtString\n - elseif\n - emptyDecl\n - emptyFallthrough\n - emptyStringTest\n - equalFold\n - evalOrder\n - exitAfterDefer\n - exposedSyncMutex\n - externalErrorReassign\n - filepathJoin\n - flagDeref\n - flagName\n - hexLiteral\n - httpNoBody\n - hugeParam\n - ifElseChain\n - importShadow\n - indexAlloc\n - initClause\n - mapKey\n - methodExprCall\n - nestingReduce\n - newDeref\n - nilValReturn\n - octalLiteral\n - offBy1\n - paramTypeCombine\n - preferDecodeRune\n - preferFilepathJoin\n - preferFprint\n - preferStringWriter\n - preferWriteByte\n - ptrToRefParam\n - rangeAppendAll\n - rangeExprCopy\n - rangeValCopy\n - redundantSprint\n - regexpMust\n - regexpPattern\n - regexpSimplify\n - returnAfterHttpError\n - ruleguard\n - singleCaseSwitch\n - sliceClear\n - sloppyLen\n - sloppyReassign\n - sloppyTypeAssert\n - sortSlice\n - sprintfQuotedString\n - sqlQuery\n - stringConcatSimplify\n - stringXbytes\n - stringsCompare\n - switchTrue\n - syncMapLoadAndDelete\n - timeExprSimplify\n - todoCommentWithoutDetail\n - tooManyResultsChecker\n - truncateCmp\n - typeAssertChain\n - typeDefFirst\n - typeSwitchVar\n - typeUnparen\n - uncheckedInlineErr\n - underef\n - unlabelStmt\n - unlambda\n - unnamedResult\n - unnecessaryBlock\n - unnecessaryDefer\n - unslice\n - valSwap\n - weakCond\n - whyNoLint\n - wrapperFunc\n - yodaStyleExpr\n # Enable multiple checks by tags in addition to default checks.\n # Run `GL_DEBUG=gocritic golangci-lint run --enable=gocritic` to see all tags and checks.\n # See https://github.com/go-critic/go-critic#usage -\u003e section \"Tags\".\n # Default: []\n enabled-tags:\n - diagnostic\n - style\n - performance\n - experimental\n - opinionated\n disabled-tags:\n - diagnostic\n - style\n - performance\n - experimental\n - opinionated\n # Settings passed to gocritic.\n # The settings key is the name of a supported gocritic checker.\n # The list of supported checkers can be found at https://go-critic.com/overview.\n settings:\n # Must be valid enabled check name.\n captLocal:\n # Whether to restrict checker to params only.\n # Default: true\n paramsOnly: false\n commentedOutCode:\n # Min length of the comment that triggers a warning.\n # Default: 15\n minLength: 50\n elseif:\n # Whether to skip balanced if-else pairs.\n # Default: true\n skipBalanced: false\n hugeParam:\n # Size in bytes that makes the warning trigger.\n # Default: 80\n sizeThreshold: 70\n ifElseChain:\n # Min number of if-else blocks that makes the warning trigger.\n # Default: 2\n minThreshold: 4\n nestingReduce:\n # Min number of statements inside a branch to trigger a warning.\n # Default: 5\n bodyWidth: 4\n rangeExprCopy:\n # Size in bytes that makes the warning trigger.\n # Default: 512\n sizeThreshold: 516\n # Whether to check test functions\n # Default: true\n skipTestFuncs: false\n rangeValCopy:\n # Size in bytes that makes the warning trigger.\n # Default: 128\n sizeThreshold: 32\n # Whether to check test functions.\n # Default: true\n skipTestFuncs: false\n ruleguard:\n # Enable debug to identify which 'Where' condition was rejected.\n # The value of the parameter is the name of a function in a ruleguard file.\n #\n # When a rule is evaluated:\n # If:\n # The Match() clause is accepted; and\n # One of the conditions in the Where() clause is rejected,\n # Then:\n # ruleguard prints the specific Where() condition that was rejected.\n #\n # The option is passed to the ruleguard 'debug-group' argument.\n # Default: \"\"\n debug: 'emptyDecl'\n # Determines the behavior when an error occurs while parsing ruleguard files.\n # If flag is not set, log error and skip rule files that contain an error.\n # If flag is set, the value must be a comma-separated list of error conditions.\n # - 'all': fail on all errors.\n # - 'import': ruleguard rule imports a package that cannot be found.\n # - 'dsl': gorule file does not comply with the ruleguard DSL.\n # Default: \"\"\n failOn: dsl,import\n # Comma-separated list of file paths containing ruleguard rules.\n # By default, if a path is relative, it is relative to the directory where the golangci-lint command is executed.\n # The placeholder '${base-path}' is substituted with a path relative to the mode defined with `run.relative-path-mode`.\n # The placeholder '${config-path}' is substituted with a path relative to the configuration file.\n # Glob patterns such as 'rules-*.go' may be specified.\n # Default: \"\"\n rules: '${base-path}/ruleguard/rules-*.go,${base-path}/myrule1.go'\n # Comma-separated list of enabled groups or skip empty to enable everything.\n # Tags can be defined with # character prefix.\n # Default: \"\u003call\u003e\"\n enable: \"myGroupName,#myTagName\"\n # Comma-separated list of disabled groups or skip empty to enable everything.\n # Tags can be defined with # character prefix.\n # Default: \"\"\n disable: \"myGroupName,#myTagName\"\n tooManyResultsChecker:\n # Maximum number of results.\n # Default: 5\n maxResults: 10\n truncateCmp:\n # Whether to skip int/uint/uintptr types.\n # Default: true\n skipArchDependent: false\n underef:\n # Whether to skip (*x).method() calls where x is a pointer receiver.\n # Default: true\n skipRecvDeref: false\n unnamedResult:\n # Whether to check exported functions.\n # Default: false\n checkExported: true\n", - "gocyclo": "linters:\n settings:\n gocyclo:\n # Minimal code complexity to report.\n # Default: 30 (but we recommend 10-20)\n min-complexity: 10\n", - "godot": "linters:\n settings:\n godot:\n # Comments to be checked: `declarations`, `toplevel`, `noinline` or `all`.\n # Default: declarations\n scope: toplevel\n # List of regexps for excluding particular comment lines from check.\n # Default: []\n exclude:\n # Exclude todo and fixme comments.\n - \"^fixme:\"\n - \"^todo:\"\n # Check that each sentence ends with a period.\n # Default: true\n period: false\n # Check that each sentence starts with a capital letter.\n # Default: false\n capital: true\n", - "godox": "linters:\n settings:\n godox:\n # Report any comments starting with keywords, this is useful for TODO or FIXME comments that\n # might be left in the code accidentally and should be resolved before merging.\n # Default: [\"TODO\", \"BUG\", \"FIXME\"]\n keywords:\n - NOTE\n - OPTIMIZE # marks code that should be optimized before merging\n - HACK # marks hack-around that should be removed before merging\n", - "goheader": "linters:\n settings:\n goheader:\n # Supports two types 'const` and `regexp`.\n # Values can be used recursively.\n # Default: {}\n values:\n const:\n # Define here const type values in format k:v.\n # For example:\n COMPANY: MY COMPANY\n regexp:\n # Define here regexp type values.\n # for example:\n AUTHOR: .*@mycompany\\.com\n # The template used for checking.\n # Put here copyright header template for source code files.\n # Note: {{ YEAR }} is a builtin value that returns the year relative to the current machine time.\n # Default: \"\"\n template: |-\n {{ AUTHOR }} {{ COMPANY }} {{ YEAR }}\n SPDX-License-Identifier: Apache-2.0\n\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at:\n\n http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n # As alternative of directive 'template', you may put the path to file with the template source.\n # Useful if you need to load the template from a specific file.\n # By default, if a path is relative, it is relative to the directory where the golangci-lint command is executed.\n # The placeholder '${base-path}' is substituted with a path relative to the mode defined with `run.relative-path-mode`.\n # The placeholder '${config-path}' is substituted with a path relative to the configuration file.\n # Default: \"\"\n template-path: /path/to/my/template.tmpl\n", - "gomoddirectives": "linters:\n settings:\n gomoddirectives:\n # Allow local `replace` directives.\n # Default: false\n replace-local: true\n # List of allowed `replace` directives.\n # Default: []\n replace-allow-list:\n - launchpad.net/gocheck\n # Allow to not explain why the version has been retracted in the `retract` directives.\n # Default: false\n retract-allow-no-explanation: true\n # Forbid the use of the `exclude` directives.\n # Default: false\n exclude-forbidden: true\n # Forbid the use of the `ignore` directives (\u003e= go1.25).\n # Default: false\n ignore-forbidden: true\n # Forbid the use of the `toolchain` directive.\n # Default: false\n toolchain-forbidden: true\n # Defines a pattern to validate `toolchain` directive.\n # Default: '' (no match)\n toolchain-pattern: 'go1\\.23\\.\\d+$'\n # Forbid the use of the `tool` directives.\n # Default: false\n tool-forbidden: true\n # Forbid the use of the `godebug` directive.\n # Default: false\n go-debug-forbidden: true\n # Defines a pattern to validate `go` minimum version directive.\n # Default: '' (no match)\n go-version-pattern: '\\d\\.\\d+(\\.0)?'\n", - "gomodguard": "linters:\n settings:\n gomodguard:\n allowed:\n # List of allowed modules.\n # Default: []\n modules:\n - gopkg.in/yaml.v2\n # List of allowed module domains.\n # Default: []\n domains:\n - golang.org\n blocked:\n # List of blocked modules.\n # Default: []\n modules:\n # Blocked module.\n - github.com/uudashr/go-module:\n # Recommended modules that should be used instead. (Optional)\n recommendations:\n - golang.org/x/mod\n # Reason why the recommended module should be used. (Optional)\n reason: \"`mod` is the official go.mod parser library.\"\n # List of blocked module version constraints.\n # Default: []\n versions:\n # Blocked module with version constraint.\n - github.com/mitchellh/go-homedir:\n # Version constraint, see https://github.com/Masterminds/semver#basic-comparisons.\n version: \"\u003c 1.1.0\"\n # Reason why the version constraint exists. (Optional)\n reason: \"testing if blocked version constraint works.\"\n # Set to true to raise lint issues for packages that are loaded from a local path via replace directive.\n # Default: false\n local-replace-directives: false\n", - "gosec": "linters:\n settings:\n gosec:\n # To select a subset of rules to run.\n # Available rules: https://github.com/securego/gosec#available-rules\n # Default: [] - means include all rules\n includes:\n - G101 # Look for hard coded credentials\n - G102 # Bind to all interfaces\n - G103 # Audit the use of unsafe block\n - G104 # Audit errors not checked\n - G106 # Audit the use of ssh.InsecureIgnoreHostKey\n - G107 # Url provided to HTTP request as taint input\n - G108 # Profiling endpoint automatically exposed on /debug/pprof\n - G109 # Potential Integer overflow made by strconv.Atoi result conversion to int16/32\n - G110 # Potential DoS vulnerability via decompression bomb\n - G111 # Potential directory traversal\n - G112 # Potential slowloris attack\n - G114 # Use of net/http serve function that has no support for setting timeouts\n - G115 # Potential integer overflow when converting between integer types\n - G201 # SQL query construction using format string\n - G202 # SQL query construction using string concatenation\n - G203 # Use of unescaped data in HTML templates\n - G204 # Audit use of command execution\n - G301 # Poor file permissions used when creating a directory\n - G302 # Poor file permissions used with chmod\n - G303 # Creating tempfile using a predictable path\n - G304 # File path provided as taint input\n - G305 # File traversal when extracting zip/tar archive\n - G306 # Poor file permissions used when writing to a new file\n - G307 # Poor file permissions used when creating a file with os.Create\n - G401 # Detect the usage of MD5 or SHA1\n - G402 # Look for bad TLS connection settings\n - G403 # Ensure minimum RSA key length of 2048 bits\n - G404 # Insecure random number source (rand)\n - G405 # Detect the usage of DES or RC4\n - G406 # Detect the usage of MD4 or RIPEMD160\n - G501 # Import blocklist: crypto/md5\n - G502 # Import blocklist: crypto/des\n - G503 # Import blocklist: crypto/rc4\n - G504 # Import blocklist: net/http/cgi\n - G505 # Import blocklist: crypto/sha1\n - G506 # Import blocklist: golang.org/x/crypto/md4\n - G507 # Import blocklist: golang.org/x/crypto/ripemd160\n - G601 # Implicit memory aliasing of items from a range statement\n - G602 # Slice access out of bounds\n # To specify a set of rules to explicitly exclude.\n # Available rules: https://github.com/securego/gosec#available-rules\n # Default: []\n excludes:\n - G101 # Look for hard coded credentials\n - G102 # Bind to all interfaces\n - G103 # Audit the use of unsafe block\n - G104 # Audit errors not checked\n - G106 # Audit the use of ssh.InsecureIgnoreHostKey\n - G107 # Url provided to HTTP request as taint input\n - G108 # Profiling endpoint automatically exposed on /debug/pprof\n - G109 # Potential Integer overflow made by strconv.Atoi result conversion to int16/32\n - G110 # Potential DoS vulnerability via decompression bomb\n - G111 # Potential directory traversal\n - G112 # Potential slowloris attack\n - G114 # Use of net/http serve function that has no support for setting timeouts\n - G115 # Potential integer overflow when converting between integer types\n - G201 # SQL query construction using format string\n - G202 # SQL query construction using string concatenation\n - G203 # Use of unescaped data in HTML templates\n - G204 # Audit use of command execution\n - G301 # Poor file permissions used when creating a directory\n - G302 # Poor file permissions used with chmod\n - G303 # Creating tempfile using a predictable path\n - G304 # File path provided as taint input\n - G305 # File traversal when extracting zip/tar archive\n - G306 # Poor file permissions used when writing to a new file\n - G307 # Poor file permissions used when creating a file with os.Create\n - G401 # Detect the usage of MD5 or SHA1\n - G402 # Look for bad TLS connection settings\n - G403 # Ensure minimum RSA key length of 2048 bits\n - G404 # Insecure random number source (rand)\n - G405 # Detect the usage of DES or RC4\n - G406 # Detect the usage of MD4 or RIPEMD160\n - G501 # Import blocklist: crypto/md5\n - G502 # Import blocklist: crypto/des\n - G503 # Import blocklist: crypto/rc4\n - G504 # Import blocklist: net/http/cgi\n - G505 # Import blocklist: crypto/sha1\n - G506 # Import blocklist: golang.org/x/crypto/md4\n - G507 # Import blocklist: golang.org/x/crypto/ripemd160\n - G601 # Implicit memory aliasing of items from a range statement\n - G602 # Slice access out of bounds\n # Filter out the issues with a lower severity than the given value.\n # Valid options are: low, medium, high.\n # Default: low\n severity: medium\n # Filter out the issues with a lower confidence than the given value.\n # Valid options are: low, medium, high.\n # Default: low\n confidence: medium\n # Concurrency value.\n # Default: the number of logical CPUs usable by the current process.\n concurrency: 12\n # To specify the configuration of rules.\n config:\n # Globals are applicable to all rules.\n global:\n # If true, ignore #nosec in comments (and an alternative as well).\n # Default: false\n nosec: true\n # Add an alternative comment prefix to #nosec (both will work at the same time).\n # Default: \"\"\n \"#nosec\": \"#my-custom-nosec\"\n # Define whether nosec issues are counted as finding or not.\n # Default: false\n show-ignored: true\n # Audit mode enables addition checks that for normal code analysis might be too nosy.\n # Default: false\n audit: true\n G101:\n # Regexp pattern for variables and constants to find.\n # Default: \"(?i)passwd|pass|password|pwd|secret|token|pw|apiKey|bearer|cred\"\n pattern: \"(?i)example\"\n # If true, complain about all cases (even with low entropy).\n # Default: false\n ignore_entropy: false\n # Maximum allowed entropy of the string.\n # Default: \"80.0\"\n entropy_threshold: \"80.0\"\n # Maximum allowed value of entropy/string length.\n # Is taken into account if entropy \u003e= entropy_threshold/2.\n # Default: \"3.0\"\n per_char_threshold: \"3.0\"\n # Calculate entropy for first N chars of the string.\n # Default: \"16\"\n truncate: \"32\"\n # Additional functions to ignore while checking unhandled errors.\n # Following functions always ignored:\n # bytes.Buffer:\n # - Write\n # - WriteByte\n # - WriteRune\n # - WriteString\n # fmt:\n # - Print\n # - Printf\n # - Println\n # - Fprint\n # - Fprintf\n # - Fprintln\n # strings.Builder:\n # - Write\n # - WriteByte\n # - WriteRune\n # - WriteString\n # io.PipeWriter:\n # - CloseWithError\n # hash.Hash:\n # - Write\n # os:\n # - Unsetenv\n # Default: {}\n G104:\n fmt:\n - Fscanf\n G111:\n # Regexp pattern to find potential directory traversal.\n # Default: \"http\\\\.Dir\\\\(\\\"\\\\/\\\"\\\\)|http\\\\.Dir\\\\('\\\\/'\\\\)\"\n pattern: \"custom\\\\.Dir\\\\(\\\\)\"\n # Maximum allowed permissions mode for os.Mkdir and os.MkdirAll.\n # Default: \"0750\"\n G301: \"0750\"\n # Maximum allowed permissions mode for os.OpenFile and os.Chmod.\n # Default: \"0600\"\n G302: \"0600\"\n # Maximum allowed permissions mode for os.WriteFile and ioutil.WriteFile.\n # Default: \"0600\"\n G306: \"0600\"\n", - "gosmopolitan": "linters:\n settings:\n gosmopolitan:\n # Allow and ignore `time.Local` usages.\n #\n # Default: false\n allow-time-local: true\n # List of fully qualified names in the `full/pkg/path.name` form, to act as \"i18n escape hatches\".\n # String literals inside call-like expressions to, or struct literals of those names,\n # are exempt from the writing system check.\n #\n # Default: []\n escape-hatches:\n - 'github.com/nicksnyder/go-i18n/v2/i18n.Message'\n - 'example.com/your/project/i18n/markers.Raw'\n - 'example.com/your/project/i18n/markers.OK'\n - 'example.com/your/project/i18n/markers.TODO'\n - 'command-line-arguments.Simple'\n # List of Unicode scripts to watch for any usage in string literals.\n # https://pkg.go.dev/unicode#pkg-variables\n #\n # Default: [\"Han\"]\n watch-for-scripts:\n - Devanagari\n - Han\n - Hangul\n - Hiragana\n - Katakana\n", - "govet": "linters:\n settings:\n govet:\n # Disable all analyzers.\n # Default: false\n disable-all: true\n # Enable analyzers by name.\n # (In addition to default:\n # appends, asmdecl, assign, atomic, bools, buildtag, cgocall, composites, copylocks, defers, directive, errorsas,\n # framepointer, httpresponse, ifaceassert, loopclosure, lostcancel, nilfunc, printf, shift, sigchanyzer, slog,\n # stdmethods, stringintconv, structtag, testinggoroutine, tests, timeformat, unmarshal, unreachable, unsafeptr,\n # unusedresult\n # ).\n # Run `GL_DEBUG=govet golangci-lint run --enable=govet` to see default, all available analyzers, and enabled analyzers.\n # Default: []\n enable:\n # Check for missing values after append.\n - appends\n # Report mismatches between assembly files and Go declarations.\n - asmdecl\n # Check for useless assignments.\n - assign\n # Check for common mistakes using the sync/atomic package.\n - atomic\n # Check for non-64-bits-aligned arguments to sync/atomic functions.\n - atomicalign\n # Check for common mistakes involving boolean operators.\n - bools\n # Check //go:build and // +build directives.\n - buildtag\n # Detect some violations of the cgo pointer passing rules.\n - cgocall\n # Check for unkeyed composite literals.\n - composites\n # Check for locks erroneously passed by value.\n - copylocks\n # Check for calls of reflect.DeepEqual on error values.\n - deepequalerrors\n # Report common mistakes in defer statements.\n - defers\n # Check Go toolchain directives such as //go:debug.\n - directive\n # Report passing non-pointer or non-error values to errors.As.\n - errorsas\n # Find structs that would use less memory if their fields were sorted.\n - fieldalignment\n # Find calls to a particular function.\n - findcall\n # Report assembly that clobbers the frame pointer before saving it.\n - framepointer\n # Check format of addresses passed to net.Dial.\n - hostport\n # Report using Go 1.22 enhanced ServeMux patterns in older Go versions.\n - httpmux\n # Check for mistakes using HTTP responses.\n - httpresponse\n # Detect impossible interface-to-interface type assertions.\n - ifaceassert\n # Check references to loop variables from within nested functions.\n - loopclosure\n # Check cancel func returned by context.WithCancel is called.\n - lostcancel\n # Check for useless comparisons between functions and nil.\n - nilfunc\n # Check for redundant or impossible nil comparisons.\n - nilness\n # Check consistency of Printf format strings and arguments.\n - printf\n # Check for comparing reflect.Value values with == or reflect.DeepEqual.\n - reflectvaluecompare\n # Check for possible unintended shadowing of variables.\n - shadow\n # Check for shifts that equal or exceed the width of the integer.\n - shift\n # Check for unbuffered channel of os.Signal.\n - sigchanyzer\n # Check for invalid structured logging calls.\n - slog\n # Check the argument type of sort.Slice.\n - sortslice\n # Check signature of methods of well-known interfaces.\n - stdmethods\n # Report uses of too-new standard library symbols.\n - stdversion\n # Check for string(int) conversions.\n - stringintconv\n # Check that struct field tags conform to reflect.StructTag.Get.\n - structtag\n # Report calls to (*testing.T).Fatal from goroutines started by a test.\n - testinggoroutine\n # Check for common mistaken usages of tests and examples.\n - tests\n # Check for calls of (time.Time).Format or time.Parse with 2006-02-01.\n - timeformat\n # Report passing non-pointer or non-interface values to unmarshal.\n - unmarshal\n # Check for unreachable code.\n - unreachable\n # Check for invalid conversions of uintptr to unsafe.Pointer.\n - unsafeptr\n # Check for unused results of calls to some functions.\n - unusedresult\n # Checks for unused writes.\n - unusedwrite\n # Check for misuses of sync.WaitGroup.\n - waitgroup\n # Enable all analyzers.\n # Default: false\n enable-all: true\n # Disable analyzers by name.\n # (In addition to default\n # atomicalign, deepequalerrors, fieldalignment, findcall, nilness, reflectvaluecompare, shadow, sortslice,\n # timeformat, unusedwrite\n # ).\n # Run `GL_DEBUG=govet golangci-lint run --enable=govet` to see default, all available analyzers, and enabled analyzers.\n # Default: []\n disable:\n - appends\n - asmdecl\n - assign\n - atomic\n - atomicalign\n - bools\n - buildtag\n - cgocall\n - composites\n - copylocks\n - deepequalerrors\n - defers\n - directive\n - errorsas\n - fieldalignment\n - findcall\n - framepointer\n - hostport\n - httpmux\n - httpresponse\n - ifaceassert\n - loopclosure\n - lostcancel\n - nilfunc\n - nilness\n - printf\n - reflectvaluecompare\n - shadow\n - shift\n - sigchanyzer\n - slog\n - sortslice\n - stdmethods\n - stdversion\n - stringintconv\n - structtag\n - testinggoroutine\n - tests\n - timeformat\n - unmarshal\n - unreachable\n - unsafeptr\n - unusedresult\n - unusedwrite\n - waitgroup\n # Settings per analyzer.\n settings:\n # Analyzer name, run `go tool vet help` to see all analyzers.\n printf:\n # Comma-separated list of print function names to check (in addition to default, see `go tool vet help printf`).\n # Default: []\n funcs:\n - (github.com/golangci/golangci-lint/v2/pkg/logutils.Log).Infof\n - (github.com/golangci/golangci-lint/v2/pkg/logutils.Log).Warnf\n - (github.com/golangci/golangci-lint/v2/pkg/logutils.Log).Errorf\n - (github.com/golangci/golangci-lint/v2/pkg/logutils.Log).Fatalf\n shadow:\n # Whether to be strict about shadowing; can be noisy.\n # Default: false\n strict: true\n unusedresult:\n # Comma-separated list of functions whose results must be used.\n # (In addition to default:\n # context.WithCancel, context.WithDeadline, context.WithTimeout, context.WithValue, errors.New, fmt.Errorf,\n # fmt.Sprint, fmt.Sprintf, sort.Reverse\n # ).\n # Default: []\n funcs:\n - pkg.MyFunc\n # Comma-separated list of names of methods of type func() string whose results must be used.\n # (In addition to default Error,String).\n # Default: []\n stringmethods:\n - MyMethod\n", - "grouper": "linters:\n settings:\n grouper:\n # Require the use of a single global 'const' declaration only.\n # Default: false\n const-require-single-const: true\n # Require the use of grouped global 'const' declarations.\n # Default: false\n const-require-grouping: true\n # Require the use of a single 'import' declaration only.\n # Default: false\n import-require-single-import: true\n # Require the use of grouped 'import' declarations.\n # Default: false\n import-require-grouping: true\n # Require the use of a single global 'type' declaration only.\n # Default: false\n type-require-single-type: true\n # Require the use of grouped global 'type' declarations.\n # Default: false\n type-require-grouping: true\n # Require the use of a single global 'var' declaration only.\n # Default: false\n var-require-single-var: true\n # Require the use of grouped global 'var' declarations.\n # Default: false\n var-require-grouping: true\n", - "iface": "linters:\n settings:\n iface:\n # List of analyzers.\n # Default: [\"identical\"]\n enable:\n - identical # Identifies interfaces in the same package that have identical method sets.\n - unused # Identifies interfaces that are not used anywhere in the same package where the interface is defined.\n - opaque # Identifies functions that return interfaces, but the actual returned value is always a single concrete implementation.\n - unexported # Identifies interfaces that are not exported but are used in exported functions or methods.\n settings:\n unused:\n # List of packages path to exclude from the check.\n # Default: []\n exclude:\n - github.com/example/log\n", - "importas": "linters:\n settings:\n importas:\n # Do not allow unaliased imports of aliased packages.\n # Default: false\n no-unaliased: true\n # Do not allow non-required aliases.\n # Default: false\n no-extra-aliases: true\n # List of aliases\n # Default: []\n alias:\n # Using `servingv1` alias for `knative.dev/serving/pkg/apis/serving/v1` package.\n - pkg: knative.dev/serving/pkg/apis/serving/v1\n alias: servingv1\n # Using `autoscalingv1alpha1` alias for `knative.dev/serving/pkg/apis/autoscaling/v1alpha1` package.\n - pkg: knative.dev/serving/pkg/apis/autoscaling/v1alpha1\n alias: autoscalingv1alpha1\n # You can specify the package path by regular expression,\n # and alias by regular expression expansion syntax like below.\n # See https://github.com/julz/importas#use-regular-expression for details.\n - pkg: knative.dev/serving/pkg/apis/(\\w+)/(v[\\w\\d]+)\n alias: $1$2\n # An explicit empty alias can be used to ensure no aliases are used for a package.\n # This can be useful if `no-extra-aliases: true` doesn't fit your need.\n # Multiple packages can use an empty alias.\n - pkg: errors\n alias: \"\"\n", - "inamedparam": "linters:\n settings:\n inamedparam:\n # Skips check for interface methods with only a single parameter.\n # Default: false\n skip-single-param: true\n", - "interfacebloat": "linters:\n settings:\n interfacebloat:\n # The maximum number of methods allowed for an interface.\n # Default: 10\n max: 5\n", - "ireturn": "linters:\n settings:\n ireturn:\n # List of interfaces to allow.\n # Lists of the keywords and regular expressions matched to interface or package names can be used.\n # `allow` and `reject` settings cannot be used at the same time.\n #\n # Keywords:\n # - `empty` for `interface{}`\n # - `error` for errors\n # - `stdlib` for standard library\n # - `anon` for anonymous interfaces\n # - `generic` for generic interfaces added in go 1.18\n #\n # Default: [anon, error, empty, stdlib]\n allow:\n - anon\n # You can specify idiomatic endings for interface\n - (or|er)$\n # List of interfaces to reject.\n # Lists of the keywords and regular expressions matched to interface or package names can be used.\n # `allow` and `reject` settings cannot be used at the same time.\n #\n # Keywords:\n # - `empty` for `interface{}`\n # - `error` for errors\n # - `stdlib` for standard library\n # - `anon` for anonymous interfaces\n # - `generic` for generic interfaces added in go 1.18\n #\n # Default: []\n reject:\n - github.com\\/user\\/package\\/v4\\.Type\n", - "lll": "linters:\n settings:\n lll:\n # Max line length, lines longer will be reported.\n # '\\t' is counted as 1 character by default, and can be changed with the tab-width option.\n # Default: 120.\n line-length: 120\n # Tab width in spaces.\n # Default: 1\n tab-width: 1\n", - "loggercheck": "linters:\n settings:\n loggercheck:\n # Allow check for the github.com/go-kit/log library.\n # Default: true\n kitlog: false\n # Allow check for the k8s.io/klog/v2 library.\n # Default: true\n klog: false\n # Allow check for the github.com/go-logr/logr library.\n # Default: true\n logr: false\n # Allow check for the log/slog library.\n # Default: true\n slog: false\n # Allow check for the \"sugar logger\" from go.uber.org/zap library.\n # Default: true\n zap: false\n # Require all logging keys to be inlined constant strings.\n # Default: false\n require-string-key: true\n # Require printf-like format specifier (%s, %d for example) not present.\n # Default: false\n no-printf-like: true\n # List of custom rules to check against, where each rule is a single logger pattern, useful for wrapped loggers.\n # For example: https://github.com/timonwong/loggercheck/blob/7395ab86595781e33f7afba27ad7b55e6956ebcd/testdata/custom-rules.txt\n # Default: empty\n rules:\n - k8s.io/klog/v2.InfoS # package level exported functions\n - (github.com/go-logr/logr.Logger).Error # \"Methods\"\n - (*go.uber.org/zap.SugaredLogger).With # Also \"Methods\", but with a pointer receiver\n", - "maintidx": "linters:\n settings:\n maintidx:\n # Show functions with maintainability index lower than N.\n # A high index indicates better maintainability (it's kind of the opposite of complexity).\n # Default: 20\n under: 100\n", - "makezero": "linters:\n settings:\n makezero:\n # Allow only slices initialized with a length of zero.\n # Default: false\n always: true\n", - "misspell": "linters:\n settings:\n misspell:\n # Correct spellings using locale preferences for US or UK.\n # Setting locale to US will correct the British spelling of 'colour' to 'color'.\n # Default is to use a neutral variety of English.\n locale: US\n # Typos to ignore.\n # Should be in lower case.\n # Default: []\n ignore-rules:\n - someword\n # Extra word corrections.\n # `typo` and `correction` should only contain letters.\n # The words are case-insensitive.\n # Default: []\n extra-words:\n - typo: \"iff\"\n correction: \"if\"\n - typo: \"cancelation\"\n correction: \"cancellation\"\n # Mode of the analysis:\n # - default: checks all the file content.\n # - restricted: checks only comments.\n # Default: \"\"\n mode: restricted\n", - "mnd": "linters:\n settings:\n mnd:\n # List of enabled checks, see https://github.com/tommy-muehle/go-mnd/#checks for description.\n # Default: [\"argument\", \"case\", \"condition\", \"operation\", \"return\", \"assign\"]\n checks:\n - argument\n - case\n - condition\n - operation\n - return\n - assign\n # List of numbers to exclude from analysis.\n # The numbers should be written as string.\n # Values always ignored: \"1\", \"1.0\", \"0\" and \"0.0\".\n # Default: []\n ignored-numbers:\n - '0666'\n - '0755'\n - '42'\n # List of file patterns to exclude from analysis.\n # Values always ignored: `.+_test.go`.\n # Default: []\n ignored-files:\n - 'magic1_.+\\.go$'\n # List of function patterns to exclude from analysis.\n # Following functions are always ignored: `time.Date`,\n # `strconv.FormatInt`, `strconv.FormatUint`, `strconv.FormatFloat`,\n # `strconv.ParseInt`, `strconv.ParseUint`, `strconv.ParseFloat`.\n # Default: []\n ignored-functions:\n - '^math\\.'\n - '^http\\.StatusText$'\n", - "musttag": "linters:\n settings:\n musttag:\n # A set of custom functions to check in addition to the builtin ones.\n # Default: json, xml, gopkg.in/yaml.v3, BurntSushi/toml, mitchellh/mapstructure, jmoiron/sqlx\n functions:\n # The full name of the function, including the package.\n - name: github.com/hashicorp/hcl/v2/hclsimple.DecodeFile\n # The struct tag whose presence should be ensured.\n tag: hcl\n # The position of the argument to check.\n arg-pos: 2\n", - "nakedret": "linters:\n settings:\n nakedret:\n # Make an issue if func has more lines of code than this setting, and it has naked returns.\n # Default: 30\n max-func-lines: 31\n", - "nestif": "linters:\n settings:\n nestif:\n # Minimal complexity of if statements to report.\n # Default: 5\n min-complexity: 4\n", - "nilnil": "linters:\n settings:\n nilnil:\n # To check functions with only two return values (`return nil, nil`).\n # If disabled then returns like `return nil, nil, ..., nil` are supported.\n # Default: true\n only-two: false\n # In addition, detect opposite situation (simultaneous return of non-nil error and valid value).\n # E.g, `return clone, fh.indexer.Update(clone)` will be considered as invalid.\n # Default: false\n detect-opposite: true\n # List of return types to check.\n # Default: [\"chan\", \"func\", \"iface\", \"map\", \"ptr\", \"uintptr\", \"unsafeptr\"]\n checked-types:\n - chan\n - func\n - iface\n - map\n - ptr\n - uintptr\n - unsafeptr\n", - "nlreturn": "linters:\n settings:\n nlreturn:\n # Size of the block (including return statement that is still \"OK\"),\n # so no return split required.\n # Default: 1\n block-size: 2\n", - "nolintlint": "linters:\n settings:\n nolintlint:\n # Disable to ensure that all nolint directives actually have an effect.\n # Default: false\n allow-unused: true\n # Exclude following linters from requiring an explanation.\n # Default: []\n allow-no-explanation: []\n # Enable to require an explanation of nonzero length after each nolint directive.\n # Default: false\n require-explanation: true\n # Enable to require nolint directives to mention the specific linter being suppressed.\n # Default: false\n require-specific: true\n", - "nonamedreturns": "linters:\n settings:\n nonamedreturns:\n # Report named error if it is assigned inside defer.\n # Default: false\n report-error-in-defer: true\n", - "paralleltest": "linters:\n settings:\n paralleltest:\n # Ignore missing calls to `t.Parallel()` and only report incorrect uses of it.\n # Default: false\n ignore-missing: true\n # Ignore missing calls to `t.Parallel()` in subtests. Top-level tests are\n # still required to have `t.Parallel`, but subtests are allowed to skip it.\n # Default: false\n ignore-missing-subtests: true\n", - "perfsprint": "linters:\n settings:\n perfsprint:\n # Enable/disable optimization of integer formatting.\n # Default: true\n integer-format: false\n # Optimizes even if it requires an int or uint type cast.\n # Default: true\n int-conversion: false\n # Enable/disable optimization of error formatting.\n # Default: true\n error-format: false\n # Optimizes into `err.Error()` even if it is only equivalent for non-nil errors.\n # Default: false\n err-error: true\n # Optimizes `fmt.Errorf`.\n # Default: true\n errorf: false\n # Enable/disable optimization of string formatting.\n # Default: true\n string-format: false\n # Optimizes `fmt.Sprintf` with only one argument.\n # Default: true\n sprintf1: false\n # Optimizes into strings concatenation.\n # Default: true\n strconcat: false\n # Enable/disable optimization of bool formatting.\n # Default: true\n bool-format: false\n # Enable/disable optimization of hex formatting.\n # Default: true\n hex-format: false\n", - "prealloc": "linters:\n settings:\n prealloc:\n # IMPORTANT: we don't recommend using this linter before doing performance profiling.\n # For most programs usage of prealloc will be a premature optimization.\n\n # Report pre-allocation suggestions only on simple loops that have no returns/breaks/continues/gotos in them.\n # Default: true\n simple: false\n # Report pre-allocation suggestions on range loops.\n # Default: true\n range-loops: false\n # Report pre-allocation suggestions on for loops.\n # Default: false\n for-loops: true\n", - "predeclared": "linters:\n settings:\n predeclared:\n # List of predeclared identifiers to not report on.\n # Default: []\n ignore:\n - new\n - int\n # Include method names and field names in checks.\n # Default: false\n qualified-name: true\n", - "promlinter": "linters:\n settings:\n promlinter:\n # Promlinter cannot infer all metrics name in static analysis.\n # Enable strict mode will also include the errors caused by failing to parse the args.\n # Default: false\n strict: true\n # Please refer to https://github.com/yeya24/promlinter#usage for detailed usage.\n # Default: []\n disabled-linters:\n # Help detects issues related to the help text for a metric.\n - Help\n # MetricUnits detects issues with metric unit names.\n - MetricUnits\n # Counter detects issues specific to counters, as well as patterns that should only be used with counters.\n - Counter\n # HistogramSummaryReserved detects when other types of metrics use names or labels reserved for use by histograms and/or summaries.\n - HistogramSummaryReserved\n # MetricTypeInName detects when metric types are included in the metric name.\n - MetricTypeInName\n # ReservedChars detects colons in metric names.\n - ReservedChars\n # CamelCase detects metric names and label names written in camelCase.\n - CamelCase\n # UnitAbbreviations detects abbreviated units in the metric name.\n - UnitAbbreviations\n", - "protogetter": "linters:\n settings:\n protogetter:\n # Skip files generated by specified generators from the checking.\n # Checks only the file's initial comment, which must follow the format: \"// Code generated by \u003cgenerator-name\u003e\".\n # Files generated by protoc-gen-go, protoc-gen-go-grpc, and protoc-gen-grpc-gateway are always excluded automatically.\n # Default: []\n skip-generated-by: [\"protoc-gen-go-my-own-generator\"]\n # Skip files matching the specified glob pattern from the checking.\n # Default: []\n skip-files:\n - \"*.pb.go\"\n - \"*/vendor/*\"\n - \"/full/path/to/file.go\"\n # Skip any generated files from the checking.\n # Default: false\n skip-any-generated: true\n # Skip first argument of append function.\n # Default: false\n replace-first-arg-in-append: true\n", - "reassign": "linters:\n settings:\n reassign:\n # Patterns for global variable names that are checked for reassignment.\n # See https://github.com/curioswitch/go-reassign#usage\n # Default: [\"EOF\", \"Err.*\"]\n patterns:\n - \".*\"\n", - "recvcheck": "linters:\n settings:\n recvcheck:\n # Disables the built-in method exclusions:\n # - `MarshalText`\n # - `MarshalJSON`\n # - `MarshalYAML`\n # - `MarshalXML`\n # - `MarshalBinary`\n # - `GobEncode`\n # Default: false\n disable-builtin: true\n # User-defined method exclusions.\n # The format is `struct_name.method_name` (ex: `Foo.MethodName`).\n # A wildcard `*` can use as a struct name (ex: `*.MethodName`).\n # Default: []\n exclusions:\n - \"*.Value\"\n", - "revive": "linters:\n settings:\n revive:\n # Maximum number of open files at the same time.\n # See https://github.com/mgechev/revive#command-line-flags\n # Defaults to unlimited.\n max-open-files: 2048\n # Sets the default severity.\n # See https://github.com/mgechev/revive#configuration\n # Default: warning\n severity: error\n # Enable all available rules.\n # Default: false\n enable-all-rules: true\n # Enable validation of comment directives.\n # See https://github.com/mgechev/revive#comment-directives\n directives:\n - name: specify-disable-reason\n severity: error\n # Sets the default failure confidence.\n # This means that linting errors with less than 0.8 confidence will be ignored.\n # Default: 0.8\n confidence: 0.1\n # Run `GL_DEBUG=revive golangci-lint run --enable-only=revive` to see default, all available rules, and enabled rules.\n rules:\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#add-constant\n - name: add-constant\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - max-lit-count: \"3\"\n allow-strs: '\"\"'\n allow-ints: \"0,1,2\"\n allow-floats: \"0.0,0.,1.0,1.,2.0,2.\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#argument-limit\n - name: argument-limit\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [4]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#atomic\n - name: atomic\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#banned-characters\n - name: banned-characters\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [\"Ω\", \"Σ\", \"σ\", \"7\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#bare-return\n - name: bare-return\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#blank-imports\n - name: blank-imports\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#bool-literal-in-expr\n - name: bool-literal-in-expr\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#call-to-gc\n - name: call-to-gc\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#cognitive-complexity\n - name: cognitive-complexity\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [7]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#comment-spacings\n - name: comment-spacings\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - mypragma\n - otherpragma\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#comments-density\n - name: comments-density\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [15]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#confusing-naming\n - name: confusing-naming\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#confusing-results\n - name: confusing-results\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#constant-logical-expr\n - name: constant-logical-expr\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#context-as-argument\n - name: context-as-argument\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - allow-types-before: \"*testing.T,*github.com/user/repo/testing.Harness\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#context-keys-type\n - name: context-keys-type\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#cyclomatic\n - name: cyclomatic\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [3]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#datarace\n - name: datarace\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#deep-exit\n - name: deep-exit\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#defer\n - name: defer\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"call-chain\"\n - \"loop\"\n - \"method-call\"\n - \"recover\"\n - \"immediate-recover\"\n - \"return\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#dot-imports\n - name: dot-imports\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - allowed-packages: [\"github.com/onsi/ginkgo/v2\", \"github.com/onsi/gomega\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#duplicated-imports\n - name: duplicated-imports\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#early-return\n - name: early-return\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"preserve-scope\"\n - \"allow-jump\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#empty-block\n - name: empty-block\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#empty-lines\n - name: empty-lines\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#enforce-map-style\n - name: enforce-map-style\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"make\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#enforce-repeated-arg-type-style\n - name: enforce-repeated-arg-type-style\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"short\"\n # Or this parameter:\n - func-arg-style: \"full\"\n func-ret-val-style: \"short\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#enforce-slice-style\n - name: enforce-slice-style\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"make\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#enforce-switch-style\n - name: enforce-switch-style\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [\"allowNoDefault\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#error-naming\n - name: error-naming\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#error-return\n - name: error-return\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#error-strings\n - name: error-strings\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"xerrors.New\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#errorf\n - name: errorf\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#exported\n - name: exported\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"check-private-receivers\"\n - \"disable-stuttering-check\"\n - \"say-repetitive-instead-of-stutters\"\n - \"check-public-interface\"\n - \"disable-checks-on-constants\"\n - \"disable-checks-on-functions\"\n - \"disable-checks-on-methods\"\n - \"disable-checks-on-types\"\n - \"disable-checks-on-variables\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#file-header\n - name: file-header\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - This is the text that must appear at the top of source files.\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#file-length-limit\n - name: file-length-limit\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - max: 100\n skip-comments: true\n skip-blank-lines: true\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#filename-format\n - name: filename-format\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"^[_a-z][_a-z0-9]*\\\\.go$\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#flag-parameter\n - name: flag-parameter\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#function-length\n - name: function-length\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [10, 0]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#function-result-limit\n - name: function-result-limit\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [3]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#get-return\n - name: get-return\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#identical-branches\n - name: identical-branches\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#if-return\n - name: if-return\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#import-alias-naming\n - name: import-alias-naming\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"^[a-z][a-z0-9]{0,}$\"\n # Or this parameter:\n - allow-regex: \"^[a-z][a-z0-9]{0,}$\"\n deny-regex: '^v\\d+$'\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#import-shadowing\n - name: import-shadowing\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#imports-blocklist\n - name: imports-blocklist\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"crypto/md5\"\n - \"crypto/sha1\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#increment-decrement\n - name: increment-decrement\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#indent-error-flow\n - name: indent-error-flow\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"preserve-scope\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#line-length-limit\n - name: line-length-limit\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [80]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#max-control-nesting\n - name: max-control-nesting\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [3]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#max-public-structs\n - name: max-public-structs\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments: [3]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#modifies-parameter\n - name: modifies-parameter\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#modifies-value-receiver\n - name: modifies-value-receiver\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#nested-structs\n - name: nested-structs\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#optimize-operands-order\n - name: optimize-operands-order\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#package-comments\n - name: package-comments\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#range\n - name: range\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#range-val-address\n - name: range-val-address\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#range-val-in-closure\n - name: range-val-in-closure\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#receiver-naming\n - name: receiver-naming\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - max-length: 2\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#redefines-builtin-id\n - name: redefines-builtin-id\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#redundant-build-tag\n - name: redundant-build-tag\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#redundant-import-alias\n - name: redundant-import-alias\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#redundant-test-main-exit\n - name: redundant-test-main-exit\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#string-format\n - name: string-format\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - - 'core.WriteError[1].Message'\n - '/^([^A-Z]|$)/'\n - must not start with a capital letter\n - - 'fmt.Errorf[0]'\n - '/(^|[^\\.!?])$/'\n - must not end in punctuation\n - - panic\n - '/^[^\\n]*$/'\n - must not contain line breaks\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#string-of-int\n - name: string-of-int\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#struct-tag\n - name: struct-tag\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"json,inline\"\n - \"bson,outline,gnu\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#superfluous-else\n - name: superfluous-else\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"preserve-scope\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#time-date\n - name: time-date\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#time-equal\n - name: time-equal\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#time-naming\n - name: time-naming\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unchecked-type-assertion\n - name: unchecked-type-assertion\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - accept-ignored-assertion-result: true\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unconditional-recursion\n - name: unconditional-recursion\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unexported-naming\n - name: unexported-naming\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unexported-return\n - name: unexported-return\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unhandled-error\n - name: unhandled-error\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - \"^fmt.Printf\"\n - \"myFunction\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unnecessary-format\n - name: unnecessary-format\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unnecessary-stmt\n - name: unnecessary-stmt\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unreachable-code\n - name: unreachable-code\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unused-parameter\n - name: unused-parameter\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - allow-regex: \"^_\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#unused-receiver\n - name: unused-receiver\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - allow-regex: \"^_\"\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#use-any\n - name: use-any\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#use-errors-new\n - name: use-errors-new\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#use-fmt-print\n - name: use-fmt-print\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#useless-break\n - name: useless-break\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#var-declaration\n - name: var-declaration\n severity: warning\n disabled: false\n exclude: [\"\"]\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#var-naming\n - name: var-naming\n severity: warning\n disabled: false\n exclude: [\"\"]\n arguments:\n - [\"ID\"] # AllowList\n - [\"VM\"] # DenyList\n - - skip-initialism-name-checks: true\n upper-case-const: true\n skip-package-name-checks: true\n extra-bad-package-names:\n - helpers\n - models\n # https://github.com/mgechev/revive/blob/HEAD/RULES_DESCRIPTIONS.md#waitgroup-by-value\n - name: waitgroup-by-value\n severity: warning\n disabled: false\n exclude: [\"\"]\n", - "rowserrcheck": "linters:\n settings:\n rowserrcheck:\n # database/sql is always checked.\n # Default: []\n packages:\n - github.com/jmoiron/sqlx\n", - "sloglint": "linters:\n settings:\n sloglint:\n # Enforce not mixing key-value pairs and attributes.\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#no-mixed-arguments\n # Default: true\n no-mixed-args: false\n # Enforce using key-value pairs only (overrides no-mixed-args, incompatible with attr-only).\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#key-value-pairs-only\n # Default: false\n kv-only: true\n # Enforce using attributes only (overrides no-mixed-args, incompatible with kv-only).\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#attributes-only\n # Default: false\n attr-only: true\n # Enforce not using global loggers.\n # Values:\n # - \"\": disabled\n # - \"all\": report all global loggers\n # - \"default\": report only the default slog logger\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#no-global\n # Default: \"\"\n no-global: \"all\"\n # Enforce using methods that accept a context.\n # Values:\n # - \"\": disabled\n # - \"all\": report all contextless calls\n # - \"scope\": report only if a context exists in the scope of the outermost function\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#context-only\n # Default: \"\"\n context: \"all\"\n # Enforce using static values for log messages.\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#static-messages\n # Default: false\n static-msg: true\n # Enforce message style.\n # Values: lowercased, capitalized\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#message-style\n # Default: \"\"\n msg-style: capitalized\n # Enforce using constants instead of raw keys.\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#no-raw-keys\n # Default: false\n no-raw-keys: true\n # Enforce key naming convention.\n # Values: snake, kebab, camel, pascal\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#key-naming-convention\n # Default: \"\"\n key-naming-case: snake\n # Enforce not using specific keys.\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#forbidden-keys\n # Default: []\n forbidden-keys:\n - time\n - level\n - msg\n - source\n - foo\n # Enforce putting arguments on separate lines.\n # https://github.com/go-simpler/sloglint?tab=readme-ov-file#arguments-on-separate-lines\n # Default: false\n args-on-sep-lines: true\n", - "spancheck": "linters:\n settings:\n spancheck:\n # Checks to enable.\n # Options include:\n # - `end`: check that `span.End()` is called\n # - `record-error`: check that `span.RecordError(err)` is called when an error is returned\n # - `set-status`: check that `span.SetStatus(codes.Error, msg)` is called when an error is returned\n # Default: [\"end\"]\n checks:\n - end\n - record-error\n - set-status\n # A list of regexes for function signatures that silence `record-error` and `set-status` reports\n # if found in the call path to a returned error.\n # https://github.com/jjti/go-spancheck#ignore-check-signatures\n # Default: []\n ignore-check-signatures:\n - \"telemetry.RecordError\"\n # A list of regexes for additional function signatures that create spans.\n # This is useful if you have a utility method to create spans.\n # Each entry should be of the form `\u003cregex\u003e:\u003ctelemetry-type\u003e`, where `telemetry-type` can be `opentelemetry` or `opencensus`.\n # https://github.com/jjti/go-spancheck#extra-start-span-signatures\n # Default: []\n extra-start-span-signatures:\n - \"github.com/user/repo/telemetry/trace.Start:opentelemetry\"\n", - "staticcheck": "linters:\n settings:\n staticcheck:\n # https://staticcheck.dev/docs/configuration/options/#dot_import_whitelist\n # Default: [\"github.com/mmcloughlin/avo/build\", \"github.com/mmcloughlin/avo/operand\", \"github.com/mmcloughlin/avo/reg\"]\n dot-import-whitelist:\n - fmt\n # https://staticcheck.dev/docs/configuration/options/#initialisms\n # Default: [\"ACL\", \"API\", \"ASCII\", \"CPU\", \"CSS\", \"DNS\", \"EOF\", \"GUID\", \"HTML\", \"HTTP\", \"HTTPS\", \"ID\", \"IP\", \"JSON\", \"QPS\", \"RAM\", \"RPC\", \"SLA\", \"SMTP\", \"SQL\", \"SSH\", \"TCP\", \"TLS\", \"TTL\", \"UDP\", \"UI\", \"GID\", \"UID\", \"UUID\", \"URI\", \"URL\", \"UTF8\", \"VM\", \"XML\", \"XMPP\", \"XSRF\", \"XSS\", \"SIP\", \"RTP\", \"AMQP\", \"DB\", \"TS\"]\n initialisms: [\"ACL\", \"API\", \"ASCII\", \"CPU\", \"CSS\", \"DNS\", \"EOF\", \"GUID\", \"HTML\", \"HTTP\", \"HTTPS\", \"ID\", \"IP\", \"JSON\", \"QPS\", \"RAM\", \"RPC\", \"SLA\", \"SMTP\", \"SQL\", \"SSH\", \"TCP\", \"TLS\", \"TTL\", \"UDP\", \"UI\", \"GID\", \"UID\", \"UUID\", \"URI\", \"URL\", \"UTF8\", \"VM\", \"XML\", \"XMPP\", \"XSRF\", \"XSS\", \"SIP\", \"RTP\", \"AMQP\", \"DB\", \"TS\"]\n # https://staticcheck.dev/docs/configuration/options/#http_status_code_whitelist\n # Default: [\"200\", \"400\", \"404\", \"500\"]\n http-status-code-whitelist: [\"200\", \"400\", \"404\", \"500\"]\n # SAxxxx checks in https://staticcheck.dev/docs/configuration/options/#checks\n # Example (to disable some checks): [ \"all\", \"-SA1000\", \"-SA1001\"]\n # Run `GL_DEBUG=staticcheck golangci-lint run --enable=staticcheck` to see all available checks and enabled by config checks.\n # Default: [\"all\", \"-ST1000\", \"-ST1003\", \"-ST1016\", \"-ST1020\", \"-ST1021\", \"-ST1022\"]\n checks:\n # Invalid regular expression.\n # https://staticcheck.dev/docs/checks/#SA1000\n - SA1000\n # Invalid template.\n # https://staticcheck.dev/docs/checks/#SA1001\n - SA1001\n # Invalid format in 'time.Parse'.\n # https://staticcheck.dev/docs/checks/#SA1002\n - SA1002\n # Unsupported argument to functions in 'encoding/binary'.\n # https://staticcheck.dev/docs/checks/#SA1003\n - SA1003\n # Suspiciously small untyped constant in 'time.Sleep'.\n # https://staticcheck.dev/docs/checks/#SA1004\n - SA1004\n # Invalid first argument to 'exec.Command'.\n # https://staticcheck.dev/docs/checks/#SA1005\n - SA1005\n # 'Printf' with dynamic first argument and no further arguments.\n # https://staticcheck.dev/docs/checks/#SA1006\n - SA1006\n # Invalid URL in 'net/url.Parse'.\n # https://staticcheck.dev/docs/checks/#SA1007\n - SA1007\n # Non-canonical key in 'http.Header' map.\n # https://staticcheck.dev/docs/checks/#SA1008\n - SA1008\n # '(*regexp.Regexp).FindAll' called with 'n == 0', which will always return zero results.\n # https://staticcheck.dev/docs/checks/#SA1010\n - SA1010\n # Various methods in the \"strings\" package expect valid UTF-8, but invalid input is provided.\n # https://staticcheck.dev/docs/checks/#SA1011\n - SA1011\n # A nil 'context.Context' is being passed to a function, consider using 'context.TODO' instead.\n # https://staticcheck.dev/docs/checks/#SA1012\n - SA1012\n # 'io.Seeker.Seek' is being called with the whence constant as the first argument, but it should be the second.\n # https://staticcheck.dev/docs/checks/#SA1013\n - SA1013\n # Non-pointer value passed to 'Unmarshal' or 'Decode'.\n # https://staticcheck.dev/docs/checks/#SA1014\n - SA1014\n # Using 'time.Tick' in a way that will leak. Consider using 'time.NewTicker', and only use 'time.Tick' in tests, commands and endless functions.\n # https://staticcheck.dev/docs/checks/#SA1015\n - SA1015\n # Trapping a signal that cannot be trapped.\n # https://staticcheck.dev/docs/checks/#SA1016\n - SA1016\n # Channels used with 'os/signal.Notify' should be buffered.\n # https://staticcheck.dev/docs/checks/#SA1017\n - SA1017\n # 'strings.Replace' called with 'n == 0', which does nothing.\n # https://staticcheck.dev/docs/checks/#SA1018\n - SA1018\n # Using a deprecated function, variable, constant or field.\n # https://staticcheck.dev/docs/checks/#SA1019\n - SA1019\n # Using an invalid host:port pair with a 'net.Listen'-related function.\n # https://staticcheck.dev/docs/checks/#SA1020\n - SA1020\n # Using 'bytes.Equal' to compare two 'net.IP'.\n # https://staticcheck.dev/docs/checks/#SA1021\n - SA1021\n # Modifying the buffer in an 'io.Writer' implementation.\n # https://staticcheck.dev/docs/checks/#SA1023\n - SA1023\n # A string cutset contains duplicate characters.\n # https://staticcheck.dev/docs/checks/#SA1024\n - SA1024\n # It is not possible to use '(*time.Timer).Reset''s return value correctly.\n # https://staticcheck.dev/docs/checks/#SA1025\n - SA1025\n # Cannot marshal channels or functions.\n # https://staticcheck.dev/docs/checks/#SA1026\n - SA1026\n # Atomic access to 64-bit variable must be 64-bit aligned.\n # https://staticcheck.dev/docs/checks/#SA1027\n - SA1027\n # 'sort.Slice' can only be used on slices.\n # https://staticcheck.dev/docs/checks/#SA1028\n - SA1028\n # Inappropriate key in call to 'context.WithValue'.\n # https://staticcheck.dev/docs/checks/#SA1029\n - SA1029\n # Invalid argument in call to a 'strconv' function.\n # https://staticcheck.dev/docs/checks/#SA1030\n - SA1030\n # Overlapping byte slices passed to an encoder.\n # https://staticcheck.dev/docs/checks/#SA1031\n - SA1031\n # Wrong order of arguments to 'errors.Is'.\n # https://staticcheck.dev/docs/checks/#SA1032\n - SA1032\n # 'sync.WaitGroup.Add' called inside the goroutine, leading to a race condition.\n # https://staticcheck.dev/docs/checks/#SA2000\n - SA2000\n # Empty critical section, did you mean to defer the unlock?.\n # https://staticcheck.dev/docs/checks/#SA2001\n - SA2001\n # Called 'testing.T.FailNow' or 'SkipNow' in a goroutine, which isn't allowed.\n # https://staticcheck.dev/docs/checks/#SA2002\n - SA2002\n # Deferred 'Lock' right after locking, likely meant to defer 'Unlock' instead.\n # https://staticcheck.dev/docs/checks/#SA2003\n - SA2003\n # 'TestMain' doesn't call 'os.Exit', hiding test failures.\n # https://staticcheck.dev/docs/checks/#SA3000\n - SA3000\n # Assigning to 'b.N' in benchmarks distorts the results.\n # https://staticcheck.dev/docs/checks/#SA3001\n - SA3001\n # Binary operator has identical expressions on both sides.\n # https://staticcheck.dev/docs/checks/#SA4000\n - SA4000\n # '\u0026*x' gets simplified to 'x', it does not copy 'x'.\n # https://staticcheck.dev/docs/checks/#SA4001\n - SA4001\n # Comparing unsigned values against negative values is pointless.\n # https://staticcheck.dev/docs/checks/#SA4003\n - SA4003\n # The loop exits unconditionally after one iteration.\n # https://staticcheck.dev/docs/checks/#SA4004\n - SA4004\n # Field assignment that will never be observed. Did you mean to use a pointer receiver?.\n # https://staticcheck.dev/docs/checks/#SA4005\n - SA4005\n # A value assigned to a variable is never read before being overwritten. Forgotten error check or dead code?.\n # https://staticcheck.dev/docs/checks/#SA4006\n - SA4006\n # The variable in the loop condition never changes, are you incrementing the wrong variable?.\n # https://staticcheck.dev/docs/checks/#SA4008\n - SA4008\n # A function argument is overwritten before its first use.\n # https://staticcheck.dev/docs/checks/#SA4009\n - SA4009\n # The result of 'append' will never be observed anywhere.\n # https://staticcheck.dev/docs/checks/#SA4010\n - SA4010\n # Break statement with no effect. Did you mean to break out of an outer loop?.\n # https://staticcheck.dev/docs/checks/#SA4011\n - SA4011\n # Comparing a value against NaN even though no value is equal to NaN.\n # https://staticcheck.dev/docs/checks/#SA4012\n - SA4012\n # Negating a boolean twice ('!!b') is the same as writing 'b'. This is either redundant, or a typo.\n # https://staticcheck.dev/docs/checks/#SA4013\n - SA4013\n # An if/else if chain has repeated conditions and no side-effects; if the condition didn't match the first time, it won't match the second time, either.\n # https://staticcheck.dev/docs/checks/#SA4014\n - SA4014\n # Calling functions like 'math.Ceil' on floats converted from integers doesn't do anything useful.\n # https://staticcheck.dev/docs/checks/#SA4015\n - SA4015\n # Certain bitwise operations, such as 'x ^ 0', do not do anything useful.\n # https://staticcheck.dev/docs/checks/#SA4016\n - SA4016\n # Discarding the return values of a function without side effects, making the call pointless.\n # https://staticcheck.dev/docs/checks/#SA4017\n - SA4017\n # Self-assignment of variables.\n # https://staticcheck.dev/docs/checks/#SA4018\n - SA4018\n # Multiple, identical build constraints in the same file.\n # https://staticcheck.dev/docs/checks/#SA4019\n - SA4019\n # Unreachable case clause in a type switch.\n # https://staticcheck.dev/docs/checks/#SA4020\n - SA4020\n # \"x = append(y)\" is equivalent to \"x = y\".\n # https://staticcheck.dev/docs/checks/#SA4021\n - SA4021\n # Comparing the address of a variable against nil.\n # https://staticcheck.dev/docs/checks/#SA4022\n - SA4022\n # Impossible comparison of interface value with untyped nil.\n # https://staticcheck.dev/docs/checks/#SA4023\n - SA4023\n # Checking for impossible return value from a builtin function.\n # https://staticcheck.dev/docs/checks/#SA4024\n - SA4024\n # Integer division of literals that results in zero.\n # https://staticcheck.dev/docs/checks/#SA4025\n - SA4025\n # Go constants cannot express negative zero.\n # https://staticcheck.dev/docs/checks/#SA4026\n - SA4026\n # '(*net/url.URL).Query' returns a copy, modifying it doesn't change the URL.\n # https://staticcheck.dev/docs/checks/#SA4027\n - SA4027\n # 'x % 1' is always zero.\n # https://staticcheck.dev/docs/checks/#SA4028\n - SA4028\n # Ineffective attempt at sorting slice.\n # https://staticcheck.dev/docs/checks/#SA4029\n - SA4029\n # Ineffective attempt at generating random number.\n # https://staticcheck.dev/docs/checks/#SA4030\n - SA4030\n # Checking never-nil value against nil.\n # https://staticcheck.dev/docs/checks/#SA4031\n - SA4031\n # Comparing 'runtime.GOOS' or 'runtime.GOARCH' against impossible value.\n # https://staticcheck.dev/docs/checks/#SA4032\n - SA4032\n # Assignment to nil map.\n # https://staticcheck.dev/docs/checks/#SA5000\n - SA5000\n # Deferring 'Close' before checking for a possible error.\n # https://staticcheck.dev/docs/checks/#SA5001\n - SA5001\n # The empty for loop (\"for {}\") spins and can block the scheduler.\n # https://staticcheck.dev/docs/checks/#SA5002\n - SA5002\n # Defers in infinite loops will never execute.\n # https://staticcheck.dev/docs/checks/#SA5003\n - SA5003\n # \"for { select { ...\" with an empty default branch spins.\n # https://staticcheck.dev/docs/checks/#SA5004\n - SA5004\n # The finalizer references the finalized object, preventing garbage collection.\n # https://staticcheck.dev/docs/checks/#SA5005\n - SA5005\n # Infinite recursive call.\n # https://staticcheck.dev/docs/checks/#SA5007\n - SA5007\n # Invalid struct tag.\n # https://staticcheck.dev/docs/checks/#SA5008\n - SA5008\n # Invalid Printf call.\n # https://staticcheck.dev/docs/checks/#SA5009\n - SA5009\n # Impossible type assertion.\n # https://staticcheck.dev/docs/checks/#SA5010\n - SA5010\n # Possible nil pointer dereference.\n # https://staticcheck.dev/docs/checks/#SA5011\n - SA5011\n # Passing odd-sized slice to function expecting even size.\n # https://staticcheck.dev/docs/checks/#SA5012\n - SA5012\n # Using 'regexp.Match' or related in a loop, should use 'regexp.Compile'.\n # https://staticcheck.dev/docs/checks/#SA6000\n - SA6000\n # Missing an optimization opportunity when indexing maps by byte slices.\n # https://staticcheck.dev/docs/checks/#SA6001\n - SA6001\n # Storing non-pointer values in 'sync.Pool' allocates memory.\n # https://staticcheck.dev/docs/checks/#SA6002\n - SA6002\n # Converting a string to a slice of runes before ranging over it.\n # https://staticcheck.dev/docs/checks/#SA6003\n - SA6003\n # Inefficient string comparison with 'strings.ToLower' or 'strings.ToUpper'.\n # https://staticcheck.dev/docs/checks/#SA6005\n - SA6005\n # Using io.WriteString to write '[]byte'.\n # https://staticcheck.dev/docs/checks/#SA6006\n - SA6006\n # Defers in range loops may not run when you expect them to.\n # https://staticcheck.dev/docs/checks/#SA9001\n - SA9001\n # Using a non-octal 'os.FileMode' that looks like it was meant to be in octal.\n # https://staticcheck.dev/docs/checks/#SA9002\n - SA9002\n # Empty body in an if or else branch.\n # https://staticcheck.dev/docs/checks/#SA9003\n - SA9003\n # Only the first constant has an explicit type.\n # https://staticcheck.dev/docs/checks/#SA9004\n - SA9004\n # Trying to marshal a struct with no public fields nor custom marshaling.\n # https://staticcheck.dev/docs/checks/#SA9005\n - SA9005\n # Dubious bit shifting of a fixed size integer value.\n # https://staticcheck.dev/docs/checks/#SA9006\n - SA9006\n # Deleting a directory that shouldn't be deleted.\n # https://staticcheck.dev/docs/checks/#SA9007\n - SA9007\n # 'else' branch of a type assertion is probably not reading the right value.\n # https://staticcheck.dev/docs/checks/#SA9008\n - SA9008\n # Ineffectual Go compiler directive.\n # https://staticcheck.dev/docs/checks/#SA9009\n - SA9009\n # Incorrect or missing package comment.\n # https://staticcheck.dev/docs/checks/#ST1000\n - ST1000\n # Dot imports are discouraged.\n # https://staticcheck.dev/docs/checks/#ST1001\n - ST1001\n # Poorly chosen identifier.\n # https://staticcheck.dev/docs/checks/#ST1003\n - ST1003\n # Incorrectly formatted error string.\n # https://staticcheck.dev/docs/checks/#ST1005\n - ST1005\n # Poorly chosen receiver name.\n # https://staticcheck.dev/docs/checks/#ST1006\n - ST1006\n # A function's error value should be its last return value.\n # https://staticcheck.dev/docs/checks/#ST1008\n - ST1008\n # Poorly chosen name for variable of type 'time.Duration'.\n # https://staticcheck.dev/docs/checks/#ST1011\n - ST1011\n # Poorly chosen name for error variable.\n # https://staticcheck.dev/docs/checks/#ST1012\n - ST1012\n # Should use constants for HTTP error codes, not magic numbers.\n # https://staticcheck.dev/docs/checks/#ST1013\n - ST1013\n # A switch's default case should be the first or last case.\n # https://staticcheck.dev/docs/checks/#ST1015\n - ST1015\n # Use consistent method receiver names.\n # https://staticcheck.dev/docs/checks/#ST1016\n - ST1016\n # Don't use Yoda conditions.\n # https://staticcheck.dev/docs/checks/#ST1017\n - ST1017\n # Avoid zero-width and control characters in string literals.\n # https://staticcheck.dev/docs/checks/#ST1018\n - ST1018\n # Importing the same package multiple times.\n # https://staticcheck.dev/docs/checks/#ST1019\n - ST1019\n # The documentation of an exported function should start with the function's name.\n # https://staticcheck.dev/docs/checks/#ST1020\n - ST1020\n # The documentation of an exported type should start with type's name.\n # https://staticcheck.dev/docs/checks/#ST1021\n - ST1021\n # The documentation of an exported variable or constant should start with variable's name.\n # https://staticcheck.dev/docs/checks/#ST1022\n - ST1022\n # Redundant type in variable declaration.\n # https://staticcheck.dev/docs/checks/#ST1023\n - ST1023\n # Use plain channel send or receive instead of single-case select.\n # https://staticcheck.dev/docs/checks/#S1000\n - S1000\n # Replace for loop with call to copy.\n # https://staticcheck.dev/docs/checks/#S1001\n - S1001\n # Omit comparison with boolean constant.\n # https://staticcheck.dev/docs/checks/#S1002\n - S1002\n # Replace call to 'strings.Index' with 'strings.Contains'.\n # https://staticcheck.dev/docs/checks/#S1003\n - S1003\n # Replace call to 'bytes.Compare' with 'bytes.Equal'.\n # https://staticcheck.dev/docs/checks/#S1004\n - S1004\n # Drop unnecessary use of the blank identifier.\n # https://staticcheck.dev/docs/checks/#S1005\n - S1005\n # Use \"for { ... }\" for infinite loops.\n # https://staticcheck.dev/docs/checks/#S1006\n - S1006\n # Simplify regular expression by using raw string literal.\n # https://staticcheck.dev/docs/checks/#S1007\n - S1007\n # Simplify returning boolean expression.\n # https://staticcheck.dev/docs/checks/#S1008\n - S1008\n # Omit redundant nil check on slices, maps, and channels.\n # https://staticcheck.dev/docs/checks/#S1009\n - S1009\n # Omit default slice index.\n # https://staticcheck.dev/docs/checks/#S1010\n - S1010\n # Use a single 'append' to concatenate two slices.\n # https://staticcheck.dev/docs/checks/#S1011\n - S1011\n # Replace 'time.Now().Sub(x)' with 'time.Since(x)'.\n # https://staticcheck.dev/docs/checks/#S1012\n - S1012\n # Use a type conversion instead of manually copying struct fields.\n # https://staticcheck.dev/docs/checks/#S1016\n - S1016\n # Replace manual trimming with 'strings.TrimPrefix'.\n # https://staticcheck.dev/docs/checks/#S1017\n - S1017\n # Use \"copy\" for sliding elements.\n # https://staticcheck.dev/docs/checks/#S1018\n - S1018\n # Simplify \"make\" call by omitting redundant arguments.\n # https://staticcheck.dev/docs/checks/#S1019\n - S1019\n # Omit redundant nil check in type assertion.\n # https://staticcheck.dev/docs/checks/#S1020\n - S1020\n # Merge variable declaration and assignment.\n # https://staticcheck.dev/docs/checks/#S1021\n - S1021\n # Omit redundant control flow.\n # https://staticcheck.dev/docs/checks/#S1023\n - S1023\n # Replace 'x.Sub(time.Now())' with 'time.Until(x)'.\n # https://staticcheck.dev/docs/checks/#S1024\n - S1024\n # Don't use 'fmt.Sprintf(\"%s\", x)' unnecessarily.\n # https://staticcheck.dev/docs/checks/#S1025\n - S1025\n # Simplify error construction with 'fmt.Errorf'.\n # https://staticcheck.dev/docs/checks/#S1028\n - S1028\n # Range over the string directly.\n # https://staticcheck.dev/docs/checks/#S1029\n - S1029\n # Use 'bytes.Buffer.String' or 'bytes.Buffer.Bytes'.\n # https://staticcheck.dev/docs/checks/#S1030\n - S1030\n # Omit redundant nil check around loop.\n # https://staticcheck.dev/docs/checks/#S1031\n - S1031\n # Use 'sort.Ints(x)', 'sort.Float64s(x)', and 'sort.Strings(x)'.\n # https://staticcheck.dev/docs/checks/#S1032\n - S1032\n # Unnecessary guard around call to \"delete\".\n # https://staticcheck.dev/docs/checks/#S1033\n - S1033\n # Use result of type assertion to simplify cases.\n # https://staticcheck.dev/docs/checks/#S1034\n - S1034\n # Redundant call to 'net/http.CanonicalHeaderKey' in method call on 'net/http.Header'.\n # https://staticcheck.dev/docs/checks/#S1035\n - S1035\n # Unnecessary guard around map access.\n # https://staticcheck.dev/docs/checks/#S1036\n - S1036\n # Elaborate way of sleeping.\n # https://staticcheck.dev/docs/checks/#S1037\n - S1037\n # Unnecessarily complex way of printing formatted string.\n # https://staticcheck.dev/docs/checks/#S1038\n - S1038\n # Unnecessary use of 'fmt.Sprint'.\n # https://staticcheck.dev/docs/checks/#S1039\n - S1039\n # Type assertion to current type.\n # https://staticcheck.dev/docs/checks/#S1040\n - S1040\n # Apply De Morgan's law.\n # https://staticcheck.dev/docs/checks/#QF1001\n - QF1001\n # Convert untagged switch to tagged switch.\n # https://staticcheck.dev/docs/checks/#QF1002\n - QF1002\n # Convert if/else-if chain to tagged switch.\n # https://staticcheck.dev/docs/checks/#QF1003\n - QF1003\n # Use 'strings.ReplaceAll' instead of 'strings.Replace' with 'n == -1'.\n # https://staticcheck.dev/docs/checks/#QF1004\n - QF1004\n # Expand call to 'math.Pow'.\n # https://staticcheck.dev/docs/checks/#QF1005\n - QF1005\n # Lift 'if'+'break' into loop condition.\n # https://staticcheck.dev/docs/checks/#QF1006\n - QF1006\n # Merge conditional assignment into variable declaration.\n # https://staticcheck.dev/docs/checks/#QF1007\n - QF1007\n # Omit embedded fields from selector expression.\n # https://staticcheck.dev/docs/checks/#QF1008\n - QF1008\n # Use 'time.Time.Equal' instead of '==' operator.\n # https://staticcheck.dev/docs/checks/#QF1009\n - QF1009\n # Convert slice of bytes to string when printing it.\n # https://staticcheck.dev/docs/checks/#QF1010\n - QF1010\n # Omit redundant type from variable declaration.\n # https://staticcheck.dev/docs/checks/#QF1011\n - QF1011\n # Use 'fmt.Fprintf(x, ...)' instead of 'x.Write(fmt.Sprintf(...))'.\n # https://staticcheck.dev/docs/checks/#QF1012\n - QF1012\n", - "tagalign": "linters:\n settings:\n tagalign:\n # Align and sort can be used together or separately.\n #\n # Whether enable align. If true, the struct tags will be aligned.\n # E.g.:\n # type FooBar struct {\n # Bar string `json:\"bar\" validate:\"required\"`\n # FooFoo int8 `json:\"foo_foo\" validate:\"required\"`\n # }\n # will be formatted to:\n # type FooBar struct {\n # Bar string `json:\"bar\" validate:\"required\"`\n # FooFoo int8 `json:\"foo_foo\" validate:\"required\"`\n # }\n # Default: true.\n align: false\n # Whether enable tags sort.\n # If true, the tags will be sorted by name in ascending order.\n # E.g.: `xml:\"bar\" json:\"bar\" validate:\"required\"` -\u003e `json:\"bar\" validate:\"required\" xml:\"bar\"`.\n # Default: true\n sort: false\n # Specify the order of tags, the other tags will be sorted by name.\n # This option will be ignored if `sort` is false.\n # Default: []\n order:\n - json\n - yaml\n - yml\n - toml\n - mapstructure\n - binding\n - validate\n # Whether enable strict style.\n # In this style, the tags will be sorted and aligned in the dictionary order,\n # and the tags with the same name will be aligned together.\n # Note: This option will be ignored if 'align' or 'sort' is false.\n # Default: false\n strict: true\n", - "tagliatelle": "linters:\n settings:\n tagliatelle:\n # Checks the struct tag name case.\n case:\n # Defines the association between tag name and case.\n # Any struct tag name can be used.\n # Supported string cases:\n # - `camel`\n # - `pascal`\n # - `kebab`\n # - `snake`\n # - `upperSnake`\n # - `goCamel`\n # - `goPascal`\n # - `goKebab`\n # - `goSnake`\n # - `upper`\n # - `lower`\n # - `header`\n rules:\n json: camel\n yaml: camel\n xml: camel\n toml: camel\n bson: camel\n avro: snake\n mapstructure: kebab\n env: upperSnake\n envconfig: upperSnake\n whatever: snake\n # Defines the association between tag name and case.\n # Important: the `extended-rules` overrides `rules`.\n # Default: empty\n extended-rules:\n json:\n # Supported string cases:\n # - `camel`\n # - `pascal`\n # - `kebab`\n # - `snake`\n # - `upperSnake`\n # - `goCamel`\n # - `goPascal`\n # - `goKebab`\n # - `goSnake`\n # - `header`\n # - `lower`\n # - `header`\n #\n # Required\n case: camel\n # Adds 'AMQP', 'DB', 'GID', 'RTP', 'SIP', 'TS' to initialisms,\n # and removes 'LHS', 'RHS' from initialisms.\n # Default: false\n extra-initialisms: true\n # Defines initialism additions and overrides.\n # Default: empty\n initialism-overrides:\n DB: true # add a new initialism\n LHS: false # disable a default initialism.\n # ...\n # Uses the struct field name to check the name of the struct tag.\n # Default: false\n use-field-name: true\n # The field names to ignore.\n # Default: []\n ignored-fields:\n - Bar\n - Foo\n # Overrides the default/root configuration.\n # Default: []\n overrides:\n - # The package path (uses `/` only as a separator).\n # Required\n pkg: foo/bar\n # Default: empty or the same as the default/root configuration.\n rules:\n json: snake\n xml: pascal\n # Default: empty or the same as the default/root configuration.\n extended-rules:\n # Same options as the base `extended-rules`.\n # Default: false (WARNING: it doesn't follow the default/root configuration)\n use-field-name: true\n # The field names to ignore.\n # Default: [] or the same as the default/root configuration.\n ignored-fields:\n - Bar\n - Foo\n # Ignore the package (takes precedence over all other configurations).\n # Default: false\n ignore: true\n", - "testifylint": "linters:\n settings:\n testifylint:\n # Enable all checkers (https://github.com/Antonboom/testifylint#checkers).\n # Default: false\n enable-all: true\n # Disable checkers by name\n # (in addition to default\n # suite-thelper\n # ).\n disable:\n - blank-import\n - bool-compare\n - compares\n - contains\n - empty\n - encoded-compare\n - equal-values\n - error-is-as\n - error-nil\n - expected-actual\n - float-compare\n - formatter\n - go-require\n - len\n - negative-positive\n - nil-compare\n - regexp\n - require-error\n - suite-broken-parallel\n - suite-dont-use-pkg\n - suite-extra-assert-call\n - suite-method-signature\n - suite-subtest-run\n - suite-thelper\n - useless-assert\n # Disable all checkers (https://github.com/Antonboom/testifylint#checkers).\n # Default: false\n disable-all: true\n # Enable checkers by name\n # (in addition to default\n # blank-import, bool-compare, compares, contains, empty, encoded-compare, equal-values, error-is-as, error-nil,\n # expected-actual, go-require, float-compare, formatter, len, negative-positive, nil-compare, regexp, require-error,\n # suite-broken-parallel, suite-dont-use-pkg, suite-extra-assert-call, suite-subtest-run, suite-method-signature,\n # useless-assert\n # ).\n enable:\n - blank-import\n - bool-compare\n - compares\n - contains\n - empty\n - encoded-compare\n - equal-values\n - error-is-as\n - error-nil\n - expected-actual\n - float-compare\n - formatter\n - go-require\n - len\n - negative-positive\n - nil-compare\n - regexp\n - require-error\n - suite-broken-parallel\n - suite-dont-use-pkg\n - suite-extra-assert-call\n - suite-method-signature\n - suite-subtest-run\n - suite-thelper\n - useless-assert\n bool-compare:\n # To ignore user defined types (over builtin bool).\n # Default: false\n ignore-custom-types: true\n expected-actual:\n # Regexp for expected variable name.\n # Default: (^(exp(ected)?|want(ed)?)([A-Z]\\w*)?$)|(^(\\w*[a-z])?(Exp(ected)?|Want(ed)?)$)\n pattern: ^expected\n formatter:\n # To enable go vet's printf checks.\n # Default: true\n check-format-string: false\n # To require f-assertions (e.g. `assert.Equalf`) if format string is used, even if there are no variable-length\n # variables, i.e. it requires `require.NoErrorf` for both these cases:\n # - require.NoErrorf(t, err, \"unexpected error\")\n # - require.NoErrorf(t, err, \"unexpected error for sid: %v\", sid)\n # To understand this behavior, please read the\n # https://github.com/Antonboom/testifylint?tab=readme-ov-file#historical-reference-of-formatter.\n # Default: false\n require-f-funcs: true\n # To require that the first element of msgAndArgs (msg) has a string type.\n # For example, in such case assertion like `assert.True(t, b, tt.case)` will be considered as invalid.\n # Default: true\n require-string-msg: false\n go-require:\n # To ignore HTTP handlers (like http.HandlerFunc).\n # Default: false\n ignore-http-handlers: true\n require-error:\n # Regexp for assertions to analyze. If defined, then only matched error assertions will be reported.\n # Default: \"\"\n fn-pattern: ^(Errorf?|NoErrorf?)$\n suite-extra-assert-call:\n # To require or remove extra Assert() call?\n # Default: remove\n mode: require\n", - "testpackage": "linters:\n settings:\n testpackage:\n # Regexp pattern to skip files.\n # Default: \"(export|internal)_test\\\\.go\"\n skip-regexp: (export|internal)_test\\.go\n # List of packages that don't end with _test that tests are allowed to be in.\n # Default: \"main\"\n allow-packages:\n - example\n - main\n", - "thelper": "linters:\n settings:\n thelper:\n test:\n # Check *testing.T is first param (or after context.Context) of helper function.\n # Default: true\n first: false\n # Check *testing.T param has name t.\n # Default: true\n name: false\n # Check t.Helper() begins helper function.\n # Default: true\n begin: false\n benchmark:\n # Check *testing.B is first param (or after context.Context) of helper function.\n # Default: true\n first: false\n # Check *testing.B param has name b.\n # Default: true\n name: false\n # Check b.Helper() begins helper function.\n # Default: true\n begin: false\n tb:\n # Check *testing.TB is first param (or after context.Context) of helper function.\n # Default: true\n first: false\n # Check *testing.TB param has name tb.\n # Default: true\n name: false\n # Check tb.Helper() begins helper function.\n # Default: true\n begin: false\n fuzz:\n # Check *testing.F is first param (or after context.Context) of helper function.\n # Default: true\n first: false\n # Check *testing.F param has name f.\n # Default: true\n name: false\n # Check f.Helper() begins helper function.\n # Default: true\n begin: false\n", - "unconvert": "linters:\n settings:\n unconvert:\n # Remove conversions that force intermediate rounding.\n # Default: false\n fast-math: true\n # Be more conservative (experimental).\n # Default: false\n safe: true\n", - "unparam": "linters:\n settings:\n unparam:\n # Inspect exported functions.\n #\n # Set to true if no external program/library imports your code.\n # XXX: if you enable this setting, unparam will report a lot of false-positives in text editors:\n # if it's called for subdir of a project it can't find external interfaces. All text editor integrations\n # with golangci-lint call it on a directory with the changed file.\n #\n # Default: false\n check-exported: true\n", - "unused": "linters:\n settings:\n unused:\n # Mark all struct fields that have been written to as used.\n # Default: true\n field-writes-are-uses: false\n # Treat IncDec statement (e.g. `i++` or `i--`) as both read and write operation instead of just write.\n # Default: false\n post-statements-are-reads: true\n # Mark all exported fields as used.\n # default: true\n exported-fields-are-used: false\n # Mark all function parameters as used.\n # default: true\n parameters-are-used: false\n # Mark all local variables as used.\n # default: true\n local-variables-are-used: false\n # Mark all identifiers inside generated files as used.\n # Default: true\n generated-is-used: false\n", - "usestdlibvars": "linters:\n settings:\n usestdlibvars:\n # Suggest the use of http.MethodXX.\n # Default: true\n http-method: false\n # Suggest the use of http.StatusXX.\n # Default: true\n http-status-code: false\n # Suggest the use of time.Month in time.Date.\n # Default: false\n time-date-month: true\n # Suggest the use of time.Weekday.String().\n # Default: true\n time-weekday: true\n # Suggest the use of time.Month.String().\n # Default: false\n time-month: true\n # Suggest the use of time.Layout.\n # Default: false\n time-layout: true\n # Suggest the use of crypto.Hash.String().\n # Default: false\n crypto-hash: true\n # Suggest the use of rpc.DefaultXXPath.\n # Default: false\n default-rpc-path: true\n # Suggest the use of sql.LevelXX.String().\n # Default: false\n sql-isolation-level: true\n # Suggest the use of tls.SignatureScheme.String().\n # Default: false\n tls-signature-scheme: true\n # Suggest the use of constant.Kind.String().\n # Default: false\n constant-kind: true\n", - "usetesting": "linters:\n settings:\n usetesting:\n # Enable/disable `os.CreateTemp(\"\", ...)` detections.\n # Default: true\n os-create-temp: false\n # Enable/disable `os.MkdirTemp()` detections.\n # Default: true\n os-mkdir-temp: false\n # Enable/disable `os.Setenv()` detections.\n # Default: true\n os-setenv: false\n # Enable/disable `os.TempDir()` detections.\n # Default: false\n os-temp-dir: true\n # Enable/disable `os.Chdir()` detections.\n # Disabled if Go \u003c 1.24.\n # Default: true\n os-chdir: false\n # Enable/disable `context.Background()` detections.\n # Disabled if Go \u003c 1.24.\n # Default: false\n context-background: true\n # Enable/disable `context.TODO()` detections.\n # Disabled if Go \u003c 1.24.\n # Default: false\n context-todo: true\n", - "varnamelen": "linters:\n settings:\n varnamelen:\n # The longest distance, in source lines, that is being considered a \"small scope\".\n # Variables used in at most this many lines will be ignored.\n # Default: 5\n max-distance: 6\n # The minimum length of a variable's name that is considered \"long\".\n # Variable names that are at least this long will be ignored.\n # Default: 3\n min-name-length: 2\n # Check method receivers.\n # Default: false\n check-receiver: true\n # Check named return values.\n # Default: false\n check-return: true\n # Check type parameters.\n # Default: false\n check-type-param: true\n # Ignore \"ok\" variables that hold the bool return value of a type assertion.\n # Default: false\n ignore-type-assert-ok: true\n # Ignore \"ok\" variables that hold the bool return value of a map index.\n # Default: false\n ignore-map-index-ok: true\n # Ignore \"ok\" variables that hold the bool return value of a channel receive.\n # Default: false\n ignore-chan-recv-ok: true\n # Optional list of variable names that should be ignored completely.\n # Default: []\n ignore-names:\n - err\n # Optional list of variable declarations that should be ignored completely.\n # Entries must be in one of the following forms (see below for examples):\n # - for variables, parameters, named return values, method receivers, or type parameters:\n # \u003cname\u003e \u003ctype\u003e (\u003ctype\u003e can also be a pointer/slice/map/chan/...)\n # - for constants: const \u003cname\u003e\n #\n # Default: []\n ignore-decls:\n - c echo.Context\n - t testing.T\n - f *foo.Bar\n - e error\n - i int\n - const C\n - T any\n - m map[string]int\n", - "whitespace": "linters:\n settings:\n whitespace:\n # Enforces newlines (or comments) after every multi-line if statement.\n # Default: false\n multi-if: true\n # Enforces newlines (or comments) after every multi-line function signature.\n # Default: false\n multi-func: true\n", - "wrapcheck": "linters:\n settings:\n wrapcheck:\n # An array of strings specifying additional substrings of signatures to ignore.\n # Unlike 'ignore-sigs', this option extends the default set (or the set specified in 'ignore-sigs') without replacing it entirely.\n # This allows you to add specific signatures to the ignore list\n # while retaining the defaults or any items in 'ignore-sigs'.\n # Default: []\n extra-ignore-sigs:\n - .CustomError(\n - .SpecificWrap(\n # An array of strings that specify substrings of signatures to ignore.\n # If this set, it will override the default set of ignored signatures.\n # See https://github.com/tomarrell/wrapcheck#configuration for more information.\n # Default: [\".Errorf(\", \"errors.New(\", \"errors.Unwrap(\", \"errors.Join(\", \".Wrap(\", \".Wrapf(\", \".WithMessage(\", \".WithMessagef(\", \".WithStack(\"]\n ignore-sigs:\n - .Errorf(\n - errors.New(\n - errors.Unwrap(\n - errors.Join(\n - .Wrap(\n - .Wrapf(\n - .WithMessage(\n - .WithMessagef(\n - .WithStack(\n # An array of strings that specify regular expressions of signatures to ignore.\n # Default: []\n ignore-sig-regexps:\n - \\.New.*Error\\(\n # An array of strings that specify globs of packages to ignore.\n # Default: []\n ignore-package-globs:\n - encoding/*\n - github.com/pkg/*\n # An array of strings that specify regular expressions of interfaces to ignore.\n # Default: []\n ignore-interface-regexps:\n - ^(?i)c(?-i)ach(ing|e)\n # Determines whether wrapcheck should report errors returned from inside the package.\n # Default: false\n report-internal-errors: true\n", - "wsl_v5": "linters:\n settings:\n wsl_v5:\n # Allow cuddling a variable if it's used first in the immediate following block,\n # even if the statement with the block doesn't use the variable.\n # https://github.com/bombsimon/wsl/tree/main?tab=readme-ov-file#configuration\n # Default: true\n allow-first-in-block: false\n # Same as above,\n # but allows cuddling if the variable is used anywhere in the following (or nested) block.\n # https://github.com/bombsimon/wsl/tree/main?tab=readme-ov-file#configuration\n # Default: false\n allow-whole-block: true\n # If a block contains more than this number of lines,\n # the branch statement needs to be separated by whitespace.\n # https://github.com/bombsimon/wsl/tree/main?tab=readme-ov-file#configuration\n # Default: 2\n branch-max-lines: 4\n # If set to a non-negative number,\n # case blocks need to end with whitespace if exceeding this number\n # https://github.com/bombsimon/wsl/tree/main?tab=readme-ov-file#configuration\n # Default: 0\n case-max-lines: 2\n # Default checks to use.\n # Can be `all`, `none`, `default` or empty.\n # https://github.com/bombsimon/wsl/tree/main?tab=readme-ov-file#checks-and-configuration\n # Default: \"\"\n default: all\n # Enabled checks.\n # Will be additive to any presets.\n # https://github.com/bombsimon/wsl/tree/main?tab=readme-ov-file#checks-and-configuration\n # Default: []\n enable:\n - assign\n - branch\n - decl\n - defer\n - expr\n - for\n - go\n - if\n - inc-dec\n - label\n - range\n - return\n - select\n - send\n - switch\n - type-switch\n - append\n - assign-exclusive\n - assign-expr\n - err\n - leading-whitespace\n - trailing-whitespace\n # Disable checks.\n # Will be subtractive to any preset.\n # https://github.com/bombsimon/wsl/tree/main?tab=readme-ov-file#checks-and-configuration\n # Default: []\n disable:\n - assign\n - branch\n - decl\n - defer\n - expr\n - for\n - go\n - if\n - inc-dec\n - label\n - range\n - return\n - select\n - send\n - switch\n - type-switch\n - append\n - assign-exclusive\n - assign-expr\n - err\n - leading-whitespace\n - trailing-whitespace\n" -}