add validate task

This commit is contained in:
Yanick Champoux 2022-04-26 12:43:37 -04:00
parent 349588a0c6
commit c9e24ac0df

View File

@ -11,4 +11,16 @@ tasks:
sh: echo {{.SCHEMA}} | perl -pe's/ya?ml/json/g'
sources: ["{{.SCHEMA}}"]
generates: ["{{.DEST}}"]
cmds: transerialize {{.SCHEMA}} {{.DEST}}
cmds:
- transerialize {{.SCHEMA}} {{.DEST}}
validate:
silent: true
cmds:
- |
ajv validate \
--all-errors \
--errors=json \
--verbose \
-s schemas-yaml/character.yml \
-d {{.CLI_ARGS}}