Skip to content

Commit e2de548

Browse files
Update validator
1 parent 96e9548 commit e2de548

File tree

5 files changed

+10
-3
lines changed

5 files changed

+10
-3
lines changed

schemas/article.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
$schema: "https://json-schema.org/draft/2020-12/schema"
2-
$id: "/schemas/structure"
2+
$id: "/schemas/navigation"
33
title: "Wiki Article Schema"
44
type: "object"
55
required:

schemas/structure.yaml schemas/navigation.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
$schema: "https://json-schema.org/draft/2020-12/schema"
2-
$id: "/schemas/structure"
2+
$id: "/schemas/navigation"
33
title: "Wiki Navigation Schema"
44
type: "object"
55

tools/validate.cmd

+7
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
@echo off
22

3+
.\tools\yajsv.exe -s schemas/navigation.yaml "wiki/navigation.yaml"
4+
.\tools\yajsv.exe -s schemas/categories.yaml "wiki/categories.yaml"
5+
36
for /r "functions" %%f in (*.yaml) do (
47
.\tools\yajsv.exe -s schemas/function.yaml "%%f"
58
)
9+
10+
for /r "articles" %%f in (*.yaml) do (
11+
.\tools\yajsv.exe -s schemas/article.yaml "%%f"
12+
)

tools/validate.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
tools/yajsv -s schemas/structure.yaml wiki/structure.yaml
3+
tools/yajsv -s schemas/navigation.yaml wiki/navigation.yaml
44
tools/yajsv -s schemas/categories.yaml wiki/categories.yaml
55

66
find 'functions/' -name '*.yaml' -type f -print0 | xargs -0 -I {} tools/yajsv -s schemas/function.yaml {}
File renamed without changes.

0 commit comments

Comments
 (0)