From a5662689cb98896ce247b7485b89429f5b6c7749 Mon Sep 17 00:00:00 2001 From: Scot Walters Date: Sat, 17 Dec 2022 15:18:16 -0800 Subject: [PATCH 1/3] Update schema to support variable autoupdate urls --- schema.json | 50 ++++++++------------------------------------------ 1 file changed, 8 insertions(+), 42 deletions(-) diff --git a/schema.json b/schema.json index 239218cc23..d528da19b1 100644 --- a/schema.json +++ b/schema.json @@ -61,12 +61,7 @@ ] }, "type": { - "enum": [ - "md5", - "sha1", - "sha256", - "sha512" - ], + "enum": ["md5", "sha1", "sha256", "sha512"], "description": "Deprecated, hash type is determined automatically" }, "url": { @@ -210,7 +205,7 @@ "$ref": "#/definitions/shortcutsArray" }, "url": { - "$ref": "#/definitions/autoupdateUriOrArrayOfAutoupdateUris" + "$ref": "#/definitions/stringOrArrayOfStrings" } } }, @@ -279,7 +274,7 @@ "$ref": "#/definitions/shortcutsArray" }, "url": { - "$ref": "#/definitions/autoupdateUriOrArrayOfAutoupdateUris" + "$ref": "#/definitions/stringOrArrayOfStrings" } } }, @@ -422,14 +417,10 @@ }, "oneOf": [ { - "required": [ - "file" - ] + "required": ["file"] }, { - "required": [ - "script" - ] + "required": ["script"] } ], "type": "object" @@ -457,23 +448,6 @@ } ] }, - "autoupdateUriOrArrayOfAutoupdateUris": { - "anyOf": [ - { - "format": "uri", - "type": "string" - }, - { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array", - "uniqueItems": true - } - ] - }, "licenseIdentifiers": { "type": "string", "description": "License identifier based on SPDX License List https://spdx.org/licenses/", @@ -516,9 +490,7 @@ "$ref": "#/definitions/licenseIdentifiers" } }, - "required": [ - "identifier" - ], + "required": ["identifier"], "type": "object" } ] @@ -678,15 +650,9 @@ } }, "then": { - "required": [ - "url" - ] + "required": ["url"] }, - "required": [ - "version", - "homepage", - "license" - ], + "required": ["version", "homepage", "license"], "title": "scoop app manifest schema", "type": "object" } From ed2db4789a6c6f77f4d00669e562f7533f78b6ad Mon Sep 17 00:00:00 2001 From: Scot Walters Date: Sat, 17 Dec 2022 15:27:21 -0800 Subject: [PATCH 2/3] Remove formatting changes --- schema.json | 29 +++++++++++++++++++++++------ 1 file changed, 23 insertions(+), 6 deletions(-) diff --git a/schema.json b/schema.json index d528da19b1..40e32933cb 100644 --- a/schema.json +++ b/schema.json @@ -61,7 +61,12 @@ ] }, "type": { - "enum": ["md5", "sha1", "sha256", "sha512"], + "enum": [ + "md5", + "sha1", + "sha256", + "sha512" + ], "description": "Deprecated, hash type is determined automatically" }, "url": { @@ -417,10 +422,14 @@ }, "oneOf": [ { - "required": ["file"] + "required": [ + "file" + ] }, { - "required": ["script"] + "required": [ + "script" + ] } ], "type": "object" @@ -490,7 +499,9 @@ "$ref": "#/definitions/licenseIdentifiers" } }, - "required": ["identifier"], + "required": [ + "identifier" + ], "type": "object" } ] @@ -650,9 +661,15 @@ } }, "then": { - "required": ["url"] + "required": [ + "url" + ] }, - "required": ["version", "homepage", "license"], + "required": [ + "version", + "homepage", + "license" + ], "title": "scoop app manifest schema", "type": "object" } From dc033296d98150a71e9f80c8a19143c66451cdd0 Mon Sep 17 00:00:00 2001 From: Scot Walters Date: Sat, 17 Dec 2022 15:33:14 -0800 Subject: [PATCH 3/3] Changelog update --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 09eb4eea50..2e353472ca 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,10 @@ - **bucket:** Skip manifest validation if no manifest changes ([#5270](https://github.com/ScoopInstaller/Scoop/issues/5270)) +### Builds + +- **schema:** 'autoupdate' 'url' can now be any string ([#5296](https://github.com/ScoopInstaller/Scoop/issues/5296)) + ## [v0.3.1](https://github.com/ScoopInstaller/Scoop/compare/v0.3.0...v0.3.1) - 2022-11-15 ### Features