name: Validate JSON

on:
  push:
    branches:
      - main
  pull_request:
    branches:
      - main

jobs:
  validate:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Validate JSON
        uses: walbo/validate-json@v1.1.0
        with:
          files: programs/*.json
          schema: json-schema/program.json
          schema-version: draft-07
          fail-on-missing-schema: true
          strict: true
