From 6fbc81675f7f063c4ee2502b8d9f169aacb39ae4 Mon Sep 17 00:00:00 2001 From: undergroundwires Date: Fri, 2 Aug 2024 16:44:15 +0200 Subject: [PATCH] Relax linting to allow null recommendation This commit updates the YAML schema to permit explicitly setting `recommend: null` or `recommend: ~` in scripts within collection files. Previously, the schema only allowed string values for the recommendation field, restricting it to 'standard' or 'strict'. By introducing the `RecommendationLevel` definition, the schema now supports both string and null values, providing more flexibility in specifying recommendations in collection YAML files. --- src/application/collections/.schema.yaml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/application/collections/.schema.yaml b/src/application/collections/.schema.yaml index bbbeb201..d165be2b 100644 --- a/src/application/collections/.schema.yaml +++ b/src/application/collections/.schema.yaml @@ -69,6 +69,12 @@ definitions: - $ref: '#/definitions/CodeScript' - $ref: '#/definitions/CallScript' + RecommendationLevel: + oneOf: + - type: string + enum: [standard, strict] + - type: 'null' + ScriptDefinition: type: object allOf: @@ -78,8 +84,7 @@ definitions: name: type: string recommend: - type: string - enum: [standard, strict] + $ref: '#/definitions/RecommendationLevel' CodeScript: type: object