Skip to content

Commit

Permalink
Add GH Actions and fix small schema errors
Browse files Browse the repository at this point in the history
  • Loading branch information
struffel committed Sep 26, 2024
1 parent 52067b5 commit 569a58d
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 7 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/json-schema.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: JSON Schema Validation
on: [pull_request]
jobs:
validate-json-schema:
name: JSON Schema Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check if json schema was changed
id: check-for-changed-schemas
uses: tj-actions/changed-files@v41
with:
files: |
json-schema/*/*.json
- name: Validate JSON Schema files
if: steps.check-for-changed-schemas.outputs.any_changed == 'true'
uses: cardinalby/schema-validator-action@v3
with:
file: "json-schema/*/*.json"
schema: https://json-schema.org/draft/2020-12/schema
23 changes: 23 additions & 0 deletions .github/workflows/markdown.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Markdown Link Validation
on: [pull_request]
jobs:
markdown-link-check:
name: Markdown Link Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check if spec.md was changed
id: check-for-changed-spec
uses: tj-actions/changed-files@v41
with:
files: |
spec.md
- name: Validate Markdown Links
uses: gaurav-nelson/github-action-markdown-link-check@v1
if: steps.check-for-changed-spec.outputs.any_changed == 'true'
with:
use-quiet-mode: "yes"
use-verbose-mode: "yes"
config-file: "mlc_config.json"
file-path: ./spec.md
max-depth: 3
2 changes: 1 addition & 1 deletion json-schema/datablock/format.blend.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"string",
"null"
],
"pattern": "^[0-9]+\\.[0-9]+)\\.[0-9]+$"
"pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$"
},
"is_asset": {
"type": [
Expand Down
12 changes: 6 additions & 6 deletions json-schema/template/meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@
"string",
"null"
]
},
"required": [
"kind",
"version"
]
}
}
},
"required": [
"kind",
"version"
]
}

0 comments on commit 569a58d

Please sign in to comment.