diff --git a/.golangci.next.reference.yml b/.golangci.next.reference.yml index 05fddf8419a9..2bf475896288 100644 --- a/.golangci.next.reference.yml +++ b/.golangci.next.reference.yml @@ -2386,6 +2386,12 @@ linters-settings: # Default: false enable-all-rules: true + # Enable validation of comment directives. + # See https://github.com/mgechev/revive#comment-directives + directives: + - name: specify-disable-reason + severity: error + # Sets the default failure confidence. # This means that linting errors with less than 0.8 confidence will be ignored. # Default: 0.8 diff --git a/.golangci.reference.yml b/.golangci.reference.yml index 1912a5bd6500..191224c6dab3 100644 --- a/.golangci.reference.yml +++ b/.golangci.reference.yml @@ -2386,6 +2386,12 @@ linters-settings: # Default: false enable-all-rules: true + # Enable validation of comment directives. + # See https://github.com/mgechev/revive#comment-directives + directives: + - name: specify-disable-reason + severity: error + # Sets the default failure confidence. # This means that linting errors with less than 0.8 confidence will be ignored. # Default: 0.8 diff --git a/jsonschema/golangci.jsonschema.json b/jsonschema/golangci.jsonschema.json index 949ee500d26a..b52a2f532dc8 100644 --- a/jsonschema/golangci.jsonschema.json +++ b/jsonschema/golangci.jsonschema.json @@ -2657,6 +2657,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.next.jsonschema.json b/jsonschema/golangci.next.jsonschema.json index 949ee500d26a..b52a2f532dc8 100644 --- a/jsonschema/golangci.next.jsonschema.json +++ b/jsonschema/golangci.next.jsonschema.json @@ -2657,6 +2657,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.v1.57.jsonschema.json b/jsonschema/golangci.v1.57.jsonschema.json index c3a3cb899455..8ef0588837f9 100644 --- a/jsonschema/golangci.v1.57.jsonschema.json +++ b/jsonschema/golangci.v1.57.jsonschema.json @@ -2209,6 +2209,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.v1.58.jsonschema.json b/jsonschema/golangci.v1.58.jsonschema.json index 3f1fc7ec24c5..d7f790cdcca6 100644 --- a/jsonschema/golangci.v1.58.jsonschema.json +++ b/jsonschema/golangci.v1.58.jsonschema.json @@ -2380,6 +2380,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.v1.59.jsonschema.json b/jsonschema/golangci.v1.59.jsonschema.json index 384eb702366c..d1ef23834332 100644 --- a/jsonschema/golangci.v1.59.jsonschema.json +++ b/jsonschema/golangci.v1.59.jsonschema.json @@ -2463,6 +2463,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.v1.60.jsonschema.json b/jsonschema/golangci.v1.60.jsonschema.json index 0c3014180f11..087ad65b89cb 100644 --- a/jsonschema/golangci.v1.60.jsonschema.json +++ b/jsonschema/golangci.v1.60.jsonschema.json @@ -2469,6 +2469,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.v1.61.jsonschema.json b/jsonschema/golangci.v1.61.jsonschema.json index 34c6faafd1bf..18bd56fbea14 100644 --- a/jsonschema/golangci.v1.61.jsonschema.json +++ b/jsonschema/golangci.v1.61.jsonschema.json @@ -2474,6 +2474,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.v1.62.jsonschema.json b/jsonschema/golangci.v1.62.jsonschema.json index cefecd0b45e8..2e93a2fc5403 100644 --- a/jsonschema/golangci.v1.62.jsonschema.json +++ b/jsonschema/golangci.v1.62.jsonschema.json @@ -2528,6 +2528,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": { diff --git a/jsonschema/golangci.v1.63.jsonschema.json b/jsonschema/golangci.v1.63.jsonschema.json index 5bbe35fb8d9d..a5992b16c740 100644 --- a/jsonschema/golangci.v1.63.jsonschema.json +++ b/jsonschema/golangci.v1.63.jsonschema.json @@ -2606,6 +2606,32 @@ "type": "boolean", "default": false }, + "directives": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "enum": ["specify-disable-reason"] + }, + "severity": { + "type": "string", + "enum": ["warning", "error"] + }, + "exclude": { + "type": "array", + "items": { + "type": "string" + } + }, + "arguments": { + "type": "array" + } + } + } + }, "rules": { "type": "array", "items": {