From 59fdb0c5953cca1c067048f0d1b5ab8d9fd9fbb5 Mon Sep 17 00:00:00 2001 From: ccoVeille <3875889+ccoVeille@users.noreply.github.com> Date: Mon, 20 Jan 2025 15:16:57 +0100 Subject: [PATCH 1/2] feat: validate default exclusions via the schema --- jsonschema/golangci.next.jsonschema.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/jsonschema/golangci.next.jsonschema.json b/jsonschema/golangci.next.jsonschema.json index 79c5974a1bef..c2eb5e67ed9a 100644 --- a/jsonschema/golangci.next.jsonschema.json +++ b/jsonschema/golangci.next.jsonschema.json @@ -3958,7 +3958,9 @@ "description": "The list of ids of default excludes to include or disable.", "type": "array", "items": { - "type": "string" + "type": "string", + "pattern": "^EXC[0-9]{4}$", + "examples": ["EXC0001", "EXC0002", "EXC0015"] }, "default": [] }, From 6d12748942452b98151f208ffbb91068c45766eb Mon Sep 17 00:00:00 2001 From: Fernandez Ludovic Date: Mon, 20 Jan 2025 16:01:08 +0100 Subject: [PATCH 2/2] review --- jsonschema/golangci.next.jsonschema.json | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/jsonschema/golangci.next.jsonschema.json b/jsonschema/golangci.next.jsonschema.json index c2eb5e67ed9a..6e8113963ba4 100644 --- a/jsonschema/golangci.next.jsonschema.json +++ b/jsonschema/golangci.next.jsonschema.json @@ -3958,9 +3958,23 @@ "description": "The list of ids of default excludes to include or disable.", "type": "array", "items": { - "type": "string", - "pattern": "^EXC[0-9]{4}$", - "examples": ["EXC0001", "EXC0002", "EXC0015"] + "enum": [ + "EXC0001", + "EXC0002", + "EXC0003", + "EXC0004", + "EXC0005", + "EXC0006", + "EXC0007", + "EXC0008", + "EXC0009", + "EXC0010", + "EXC0011", + "EXC0012", + "EXC0013", + "EXC0014", + "EXC0015" + ] }, "default": [] },