1
0
Fork 0
mirror of https://github.com/YunoHost/apps.git synced 2024-09-03 20:06:07 +02:00

Merge pull request #1742 from Salamandar/fix_manifest_schema

Fix manifest schema
This commit is contained in:
Alexandre Aubin 2023-09-24 16:18:54 +02:00 committed by GitHub
commit 02d8b59f43
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,14 +7,21 @@
"type": "object", "type": "object",
"$defs": { "$defs": {
"translated_string": { "translated_string": {
"type": "object", "anyOf": [
"required": ["en"], {
"additionalProperties": false, "type": "object",
"patternProperties": { "required": ["en"],
"^[a-z]{2}$": { "additionalProperties": false,
"patternProperties": {
"^[a-z]{2}$": {
"type": "string"
}
}
},
{
"type": "string" "type": "string"
} }
} ]
}, },
"byte_size": { "byte_size": {
"type": "string", "type": "string",
@ -26,11 +33,11 @@
}, },
"path_absolute": { "path_absolute": {
"type": "string", "type": "string",
"pattern": "^/.*$" "pattern": "^(__[A-Z_]*__)?/.*$"
}, },
"name_and_permission": { "name_and_permission": {
"type": "string", "type": "string",
"pattern": "^([a-z_][a-z0-9_-]{0,30})(:[rwx-]{3})?$" "pattern": "^(([a-z_][a-z0-9_-]{0,30})|([_A-Z]*))(:[rwx-]{1,3})?$"
}, },
"sha256sum": { "sha256sum": {
"type": "string", "type": "string",
@ -192,6 +199,20 @@
} }
} }
] ]
},
"pattern": {
"type": "object",
"required": [],
"additionalProperties": false,
"properties": {
"regexp": {
"type": "string",
"format": "regex"
},
"error": {
"type": "string"
}
}
} }
} }
} }
@ -294,9 +315,10 @@
}, },
"additional_urls": { "additional_urls": {
"type": "array", "type": "array",
"items": { "items": {"$ref": "#/$defs/path_absolute"}
"type": "string" },
} "label": {
"type": "string"
} }
} }
} }