GitHub action for validating YAML against a schema
Find a file
2021-10-01 00:36:12 -07:00
.github fix: adding required arguments to workflow test 2021-10-01 00:27:13 -07:00
__tests__ fix: migrating to yaml validation action 2021-10-01 00:17:49 -07:00
dist fix: migrating to yaml validation action 2021-10-01 00:17:49 -07:00
src fix: migrating to yaml validation action 2021-10-01 00:17:49 -07:00
.eslintignore Initial commit 2021-09-30 21:58:11 -07:00
.eslintrc.json fix: migrating to yaml validation action 2021-10-01 00:17:49 -07:00
.gitattributes fix: migrating to yaml validation action 2021-10-01 00:17:49 -07:00
.gitignore Initial commit 2021-09-30 21:58:11 -07:00
.prettierignore Initial commit 2021-09-30 21:58:11 -07:00
.prettierrc.json Initial commit 2021-09-30 21:58:11 -07:00
action.yml fix: adding branding to action.yml 2021-10-01 00:30:23 -07:00
CODEOWNERS fix: migrating to yaml validation action 2021-10-01 00:17:49 -07:00
jest.config.js Initial commit 2021-09-30 21:58:11 -07:00
LICENSE Initial commit 2021-09-30 21:58:11 -07:00
package.json build(deps-dev): bump @vercel/ncc from 0.29.2 to 0.31.1 (#7) 2021-10-01 00:20:37 -07:00
README.md fix: updated readme to include usage instructions 2021-10-01 00:36:12 -07:00
tsconfig.json Initial commit 2021-09-30 21:58:11 -07:00
yarn.lock build(deps-dev): bump @vercel/ncc from 0.29.2 to 0.31.1 (#7) 2021-10-01 00:20:37 -07:00

Validate YAML

Github action to validate yaml files against a JSON schema

Usage

Validate your YAML files against a JSON structure by providing a schema path and a list of files.

- name: Validate YAML
  uses: brittonhayes/validate-yaml
  with:
    schemaPath: 'schema.json'
    files: |
      example/foo.yaml      

Example JSON Schema

{
  "test": {
    "structure": {
      "myValue": "string",
      "myValue2": "string"
    }
  }
}

Example Valid YAML for this schema

---
test:
  structure:
    myValue: '1'
    myValue2: '2'