-
-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathgeneral-definitions-schema.json
23 lines (23 loc) · 1.38 KB
/
general-definitions-schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "https://raw.githubusercontent.com/arduino/arduino-lint/main/etc/schemas/general-definitions-schema.json",
"title": "Shared definitions",
"description": "Definitions for use in schemas.",
"type": "object",
"definitions": {
"patternObjects": {
"semver": {
"$comment": "https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string with unused non-capturing group syntax removed.",
"pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(-((0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(\\.(0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(\\+([0-9a-zA-Z-]+(\\.[0-9a-zA-Z-]+)*))?$"
},
"relaxedSemver": {
"$comment": "https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string adjusted to also allow MAJOR.MINOR, MAJOR, and with unused non-capturing group syntax removed. For details, see https://go.bug.st/relaxed-semver",
"pattern": "^(0|[1-9]\\d*)(\\.(0|[1-9]\\d*))?(\\.(0|[1-9]\\d*))?(-((0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(\\.(0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(\\+([0-9a-zA-Z-]+(\\.[0-9a-zA-Z-]+)*))?$"
},
"containsPropertyReference": {
"$comment": "https://arduino.github.io/arduino-cli/dev/platform-specification/#configuration-files-format",
"pattern": "{.+}"
}
}
}
}