From 827f62a2304fc66e38260d367a964a0898809a7b Mon Sep 17 00:00:00 2001 From: OniriCorpe Date: Thu, 7 Mar 2024 23:32:53 +0100 Subject: [PATCH] create & add a schema to graveyard.tom --- graveyard.toml | 2 ++ schemas/graveyard.toml.schema.json | 48 ++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+) create mode 100644 schemas/graveyard.toml.schema.json diff --git a/graveyard.toml b/graveyard.toml index f4b43d73..c875af66 100644 --- a/graveyard.toml +++ b/graveyard.toml @@ -1,3 +1,5 @@ +#:schema https://github.com/YunoHost/apps/raw/master/schemas/graveyard.toml.schema.json + [anfora] category = "social_media" subtags = [ "pictures" ] diff --git a/schemas/graveyard.toml.schema.json b/schemas/graveyard.toml.schema.json new file mode 100644 index 00000000..ec22f8c8 --- /dev/null +++ b/schemas/graveyard.toml.schema.json @@ -0,0 +1,48 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema", + "$id": "https://github.com/YunoHost/apps/blob/master/schemas/graveyard.toml.schema.json", + "title": "Yunohost's graveyard.toml schema", + "version": "0", + "type": "object", + "required": [], + "additionalProperties": false, + "patternProperties": { + "^[a-z0-9_-]*$": { + "type": "object", + "required": [ + "url" + ], + "additionalProperties": false, + "properties": { + "category": { + "type": "string" + }, + "subtags": { + "type": "array", + "items": { + "type": "string" + }, + "additionalItems": false + }, + "url": { + "type": "string", + "format": "url" + }, + "antifeatures": { + "type": "array", + "items": { + "type": "string" + }, + "additionalItems": false + }, + "potential_alternative_to": { + "type": "array", + "items": { + "type": "string" + }, + "additionalItems": false + } + } + } + } +} \ No newline at end of file