Skip to content

Commit

Permalink
Relax linting to allow null recommendation
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
undergroundwires committed Aug 2, 2024
1 parent 48d97af commit 6fbc816
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/application/collections/.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,12 @@ definitions:
- $ref: '#/definitions/CodeScript'
- $ref: '#/definitions/CallScript'

RecommendationLevel:
oneOf:
- type: string
enum: [standard, strict]
- type: 'null'

ScriptDefinition:
type: object
allOf:
Expand All @@ -78,8 +84,7 @@ definitions:
name:
type: string
recommend:
type: string
enum: [standard, strict]
$ref: '#/definitions/RecommendationLevel'

CodeScript:
type: object
Expand Down

0 comments on commit 6fbc816

Please sign in to comment.