Skip to content

Commit

Permalink
added ci validation
Browse files Browse the repository at this point in the history
  • Loading branch information
LudovicMalot committed Dec 30, 2023
1 parent 1216bf3 commit f46a6a8
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflow/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Node.js CI

on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
build:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [14.x, 16.x, 18.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: npm install
- name: Check JSON Schemas
run: |
npm install -g ajv-cli
ajv compile -s schemas/*.json -r schemas/ --missing-ref=ignore
for schema in $(ls schemas); do
for file in $(find data -name "*.json"); do
ajv validate -s schemas/$schema -d $file || exit 1
done
done

0 comments on commit f46a6a8

Please sign in to comment.