diff --git a/README.md b/README.md index 955ea8197903f6df56c90fa15a226162d92a95c7..d54b9e3358419d9578633dbb87001e987981cc3f 100644 --- a/README.md +++ b/README.md @@ -6,8 +6,9 @@ Released schemas can be found at [schema.fitko.de/fit-connect/metadata](https:// ## How to bundle and lint schema ```shell -yarn # install dependencies -yarn bundle # combine files into a single schema file -yarn lint # lint -yarn test # test example schemas +yarn # install dependencies +yarn bundle # combine files into a single schema file +yarn lint # lint +yarn test # test example schemas +yarn test_higher_version # test schemas that are not compatible with the current version ``` diff --git a/schema/antragsmetadaten.schema.json b/schema/antragsmetadaten.schema.json index ac13603591441bfa90edf0a9b6f3e94e801e4204..80f88aca59e8d9908b31632a2aa012d724a0b2b4 100644 --- a/schema/antragsmetadaten.schema.json +++ b/schema/antragsmetadaten.schema.json @@ -9,15 +9,16 @@ ], "properties": { "$schema": { - "description": "URI des Schemas, dem dieser Security Event Token entspricht. Zulässig sind alle Schema-URLs mit enthaltener Version 1.x.y, wobei x und y beliebige Minor- und Patch-Versionen gemäß https://semver.org/ sein können.", + "description": "URI des Schemas, dem diese Metadaten entsprechen. Zulässig sind alle Schema-URLs mit enthaltener Version 1.x.y, wobei x und y beliebige Minor- und Patch-Versionen gemäß https://semver.org/ sein können.", "type": "string", - "pattern": "^https://schema\\.fitko\\.de/fit-connect/metadata/1\\.\\d+\\.\\d+/metadata\\.schema\\.json$" + "pattern": "^https:\\/\\/schema\\.fitko\\.de\\/fit-connect\\/metadata\\/1\\.\\d+\\.\\d+\\/metadata\\.schema\\.json$" }, "contentStructure": { "$ref": "./definitions/contentStructure.json" }, "publicServiceType": { - "$ref": "./definitions/publicServiceType.json" + "$ref": "./definitions/publicServiceType.json", + "deprecated": true }, "authenticationInformation": { "$ref": "./definitions/authenticationInformation.json" diff --git a/scripts/bundle.js b/scripts/bundle.js index 6c7881a3baf35986f430434983afd168ac02a130..9757bdb943dcf49bb6ab73a1e02c00f4d0489cb7 100644 --- a/scripts/bundle.js +++ b/scripts/bundle.js @@ -22,6 +22,6 @@ if (args.length !== 2) { let parser = new $RefParser() let schema = await parser.bundle(args[0]) - fs.writeFileSync(args[1], JSON.stringify(schema)) + fs.writeFileSync(args[1], JSON.stringify(schema).replaceAll("%24defs", "$defs")) })()