diff --git a/.gitignore b/.gitignore index cde3143c76..fdc96d2a52 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +*.log .DS_Store ._.DS_Store scoop.sublime-workspace diff --git a/CHANGELOG.md b/CHANGELOG.md index 34888675d2..fc974a8bcf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,10 @@ - **config:** Change config option to snake_case in file and SCREAMING_CASE in code ([#5116](https://github.com/ScoopInstaller/Scoop/issues/5116)) +### Builds + +- **schema**: Set manifest schema to be stricter ([#5093](https://github.com/ScoopInstaller/Scoop/issues/5093)) + ## [v0.2.4](https://github.com/ScoopInstaller/Scoop/compare/v0.2.3...v0.2.4) - 2022-08-08 ### Features diff --git a/schema.json b/schema.json index 25f4ce6eac..4ffd3e2ca3 100644 --- a/schema.json +++ b/schema.json @@ -179,19 +179,11 @@ "type": "array" }, "autoupdateArch": { + "type": "object", "additionalProperties": false, "properties": { - "url": { - "$ref": "#/definitions/autoupdateUriOrArrayOfAutoupdateUris" - }, - "hash": { - "$ref": "#/definitions/hashExtractionOrArrayOfHashExtractions" - }, - "extract_dir": { - "$ref": "#/definitions/stringOrArrayOfStrings" - }, - "extract_to": { - "$ref": "#/definitions/stringOrArrayOfStrings" + "bin": { + "$ref": "#/definitions/stringOrArrayOfStringsOrAnArrayOfArrayOfStrings" }, "env_add_path": { "$ref": "#/definitions/stringOrArrayOfStrings" @@ -199,71 +191,82 @@ "env_set": { "type": "object" }, - "bin": { - "$ref": "#/definitions/stringOrArrayOfStringsOrAnArrayOfArrayOfStrings" + "extract_dir": { + "$ref": "#/definitions/stringOrArrayOfStrings" }, - "shortcuts": { - "$ref": "#/definitions/shortcutsArray" + "hash": { + "$ref": "#/definitions/hashExtractionOrArrayOfHashExtractions" }, "installer": { + "type": "object", "additionalProperties": false, "properties": { "file": { "type": "string" } - }, - "type": "object" + } }, - "post_install": { - "$ref": "#/definitions/stringOrArrayOfStrings" + "shortcuts": { + "$ref": "#/definitions/shortcutsArray" }, - "psmodule": { + "url": { + "$ref": "#/definitions/autoupdateUriOrArrayOfAutoupdateUris" + } + } + }, + "autoupdate": { + "type": "object", + "additionalProperties": false, + "properties": { + "architecture": { + "type": "object", "additionalProperties": false, "properties": { - "name": { - "type": "string" + "32bit": { + "$ref": "#/definitions/autoupdateArch" + }, + "64bit": { + "$ref": "#/definitions/autoupdateArch" } - }, - "type": "object" + } }, - "persist": { + "bin": { "$ref": "#/definitions/stringOrArrayOfStringsOrAnArrayOfArrayOfStrings" }, + "env_add_path": { + "$ref": "#/definitions/stringOrArrayOfStrings" + }, + "env_set": { + "type": "object" + }, + "extract_dir": { + "$ref": "#/definitions/stringOrArrayOfStrings" + }, + "hash": { + "$ref": "#/definitions/hashExtractionOrArrayOfHashExtractions" + }, "license": { "$ref": "#/definitions/license" }, "notes": { "$ref": "#/definitions/stringOrArrayOfStrings" - } - }, - "type": "object" - }, - "autoupdate": { - "anyOf": [ - { - "$ref": "#/definitions/autoupdateArch" }, - { + "persist": { + "$ref": "#/definitions/stringOrArrayOfStringsOrAnArrayOfArrayOfStrings" + }, + "psmodule": { + "type": "object", + "additionalProperties": false, "properties": { - "notes": { - "$ref": "#/definitions/stringOrArrayOfStrings" - }, - "architecture": { - "type": "object", - "additionalProperties": false, - "properties": { - "32bit": { - "$ref": "#/definitions/autoupdateArch" - }, - "64bit": { - "$ref": "#/definitions/autoupdateArch" - } - } + "name": { + "type": "string" } } + }, + "url": { + "$ref": "#/definitions/autoupdateUriOrArrayOfAutoupdateUris" } - ], - "type": "object" + } }, "checkver": { "anyOf": [ @@ -614,6 +617,29 @@ "type": "string" } }, + "if": { + "properties": { + "architecture": { + "properties": { + "64bit": { + "properties": { + "url": false + } + }, + "32bit": { + "properties": { + "url": false + } + } + } + } + } + }, + "then": { + "required": [ + "url" + ] + }, "required": [ "version", "homepage",