From 42bbe403bccece314f6a114d5db8cd4ce4e15a6c Mon Sep 17 00:00:00 2001 From: Marat Reymers <16486128+maratori@users.noreply.github.com> Date: Mon, 30 May 2022 10:33:04 +0300 Subject: [PATCH] docs(gocritic): add `enable` and `disable` ruleguard settings (#2885) * docs: ruleguard: add missing `enable` and `disable` settings * Don't use go-critic groups and tags --- .golangci.reference.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.golangci.reference.yml b/.golangci.reference.yml index 8c6ee6c4..b5b4a70c 100644 --- a/.golangci.reference.yml +++ b/.golangci.reference.yml @@ -474,6 +474,7 @@ linters-settings: # ruleguard prints the specific Where() condition that was rejected. # # The flag is passed to the ruleguard 'debug-group' argument. + # Default: "" debug: 'emptyDecl' # Deprecated, use 'failOn' param. # If set to true, identical to failOn='all', otherwise failOn='' @@ -484,12 +485,22 @@ linters-settings: # - 'all': fail on all errors. # - 'import': ruleguard rule imports a package that cannot be found. # - 'dsl': gorule file does not comply with the ruleguard DSL. + # Default: "" failOn: dsl # Comma-separated list of file paths containing ruleguard rules. # If a path is relative, it is relative to the directory where the golangci-lint command is executed. # The special '${configDir}' variable is substituted with the absolute directory containing the golangci config file. # Glob patterns such as 'rules-*.go' may be specified. + # Default: "" rules: '${configDir}/ruleguard/rules-*.go,${configDir}/myrule1.go' + # Comma-separated list of enabled groups or skip empty to enable everything. + # Tags can be defined with # character prefix. + # Default: "" + enable: "myGroupName,#myTagName" + # Comma-separated list of disabled groups or skip empty to enable everything. + # Tags can be defined with # character prefix. + # Default: "" + disable: "myGroupName,#myTagName" tooManyResultsChecker: # Maximum number of results. # Default: 5