Skip to content

Commit 5dd117f

Browse files
authored
Upgrade the JSON Schema CLI to v12.10.1 (#82)
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
1 parent 77a56ac commit 5dd117f

51 files changed

Lines changed: 94 additions & 93 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Makefile

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.DEFAULT_GOAL := all
22

3-
JSONSCHEMA ?= ./node_modules/@sourcemeta/jsonschema/cli.js
3+
JSONSCHEMA ?= ./node_modules/@sourcemeta/jsonschema/npm/cli.js
44
JQ ?= jq
55
SHELLCHECK ?= shellcheck
66
TAR ?= tar
@@ -11,6 +11,7 @@ MKDIRP ?= mkdir -p
1111
RMRF ?= rm -rf
1212
NODE ?= node
1313
NPM ?= npm
14+
TIME ?= time
1415

1516
include generated.mk
1617

@@ -21,24 +22,24 @@ all: common test node_modules
2122

2223
.PHONY: common
2324
common: $(GENERATED) node_modules
24-
$(NODE) $(JSONSCHEMA) metaschema schemas meta
25-
$(NODE) $(JSONSCHEMA) lint schemas meta
26-
$(NODE) $(JSONSCHEMA) validate meta/schemas-root.json schemas
27-
$(NODE) $(JSONSCHEMA) validate meta/schemas.json schemas
28-
$(NODE) $(JSONSCHEMA) validate meta/test.json test
25+
$(TIME) $(NODE) $(JSONSCHEMA) metaschema schemas meta
26+
$(TIME) $(NODE) $(JSONSCHEMA) lint schemas meta
27+
$(TIME) $(NODE) $(JSONSCHEMA) validate meta/schemas-root.json schemas
28+
$(TIME) $(NODE) $(JSONSCHEMA) validate meta/schemas.json schemas
29+
$(TIME) $(NODE) $(JSONSCHEMA) validate meta/test.json test
2930
$(SHELLCHECK) scripts/*.sh
3031
./scripts/quality-schemas-tests-mirror.sh
3132
./scripts/quality-templates-xbrl-utr-mirror.sh
3233

3334
# TODO: Make `jsonschema fmt` automatically detect test files
3435
.PHONY: lint
3536
lint: common node_modules
36-
$(NODE) $(JSONSCHEMA) fmt schemas meta --check
37-
$(NODE) $(JSONSCHEMA) fmt test --check --default-dialect "https://json-schema.org/draft/2020-12/schema"
37+
$(TIME) $(NODE) $(JSONSCHEMA) fmt schemas meta --check
38+
$(TIME) $(NODE) $(JSONSCHEMA) fmt test --check --default-dialect "https://json-schema.org/draft/2020-12/schema"
3839

3940
.PHONY: test
4041
test: node_modules
41-
$(NODE) $(JSONSCHEMA) test ./test
42+
$(TIME) $(NODE) $(JSONSCHEMA) test ./test
4243
$(NODE) npm/cjs.test.js
4344
$(NODE) npm/esm.test.mjs
4445

package-lock.json

Lines changed: 5 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,6 @@
5151
"access": "public"
5252
},
5353
"devDependencies": {
54-
"@sourcemeta/jsonschema": "^12.7.1"
54+
"@sourcemeta/jsonschema": "^12.10.1"
5555
}
5656
}

schemas/2020-12/bipm/si/2019/base/prefixed/exagram.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"examples": [ 0, 1, 100, 1000 ],
66
"x-license": "https://github.com/sourcemeta/std/blob/main/LICENSE",
77
"x-links": [ "https://www.bipm.org/en/publications/si-brochure" ],
8-
"x-prefix-factor": 1000000000000000.0,
8+
"x-prefix-factor": 1.0000000000000000e+15,
99
"x-symbol": "Eg",
1010
"$ref": "../unit/kilogram.json"
1111
}

schemas/2020-12/bipm/si/2019/base/prefixed/petaampere.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"examples": [ 0, 1, 100, 1000 ],
66
"x-license": "https://github.com/sourcemeta/std/blob/main/LICENSE",
77
"x-links": [ "https://www.bipm.org/en/publications/si-brochure" ],
8-
"x-prefix-factor": 1000000000000000.0,
8+
"x-prefix-factor": 1.0000000000000000e+15,
99
"x-symbol": "PA",
1010
"$ref": "../unit/ampere.json"
1111
}

schemas/2020-12/bipm/si/2019/base/prefixed/petacandela.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"examples": [ 0, 1, 100, 1000 ],
66
"x-license": "https://github.com/sourcemeta/std/blob/main/LICENSE",
77
"x-links": [ "https://www.bipm.org/en/publications/si-brochure" ],
8-
"x-prefix-factor": 1000000000000000.0,
8+
"x-prefix-factor": 1.0000000000000000e+15,
99
"x-symbol": "Pcd",
1010
"$ref": "../unit/candela.json"
1111
}

schemas/2020-12/bipm/si/2019/base/prefixed/petakelvin.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"examples": [ 0, 1, 100, 1000 ],
66
"x-license": "https://github.com/sourcemeta/std/blob/main/LICENSE",
77
"x-links": [ "https://www.bipm.org/en/publications/si-brochure" ],
8-
"x-prefix-factor": 1000000000000000.0,
8+
"x-prefix-factor": 1.0000000000000000e+15,
99
"x-symbol": "PK",
1010
"$ref": "../unit/kelvin.json"
1111
}

schemas/2020-12/bipm/si/2019/base/prefixed/petametre.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"examples": [ 0, 1, 100, 1000 ],
66
"x-license": "https://github.com/sourcemeta/std/blob/main/LICENSE",
77
"x-links": [ "https://www.bipm.org/en/publications/si-brochure" ],
8-
"x-prefix-factor": 1000000000000000.0,
8+
"x-prefix-factor": 1.0000000000000000e+15,
99
"x-symbol": "Pm",
1010
"$ref": "../unit/metre.json"
1111
}

schemas/2020-12/bipm/si/2019/base/prefixed/petamole.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"examples": [ 1, 100, 1000 ],
66
"x-license": "https://github.com/sourcemeta/std/blob/main/LICENSE",
77
"x-links": [ "https://www.bipm.org/en/publications/si-brochure" ],
8-
"x-prefix-factor": 1000000000000000.0,
8+
"x-prefix-factor": 1.0000000000000000e+15,
99
"x-symbol": "Pmol",
1010
"$ref": "../unit/mole.json"
1111
}

schemas/2020-12/bipm/si/2019/base/prefixed/petasecond.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"examples": [ 0, 1, 100, 1000 ],
66
"x-license": "https://github.com/sourcemeta/std/blob/main/LICENSE",
77
"x-links": [ "https://www.bipm.org/en/publications/si-brochure" ],
8-
"x-prefix-factor": 1000000000000000.0,
8+
"x-prefix-factor": 1.0000000000000000e+15,
99
"x-symbol": "Ps",
1010
"$ref": "../unit/second.json"
1111
}

0 commit comments

Comments
 (0)