-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig-schema-v1.json
More file actions
111 lines (111 loc) · 4.59 KB
/
Copy pathconfig-schema-v1.json
File metadata and controls
111 lines (111 loc) · 4.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://github.com/chaoz23/inkcheck/blob/main/docs/config-schema-v1.json",
"title": "Inkcheck project configuration",
"type": "object",
"additionalProperties": false,
"$defs": {
"operand": {
"oneOf": [
{ "type": "object", "additionalProperties": false, "required": ["variable"], "properties": { "variable": { "type": "string", "pattern": "^[A-Za-z_][A-Za-z0-9_]*$" } } },
{ "type": "object", "additionalProperties": false, "required": ["literal"], "properties": { "literal": { "type": ["string", "number", "boolean", "null"] } } }
]
},
"condition": {
"oneOf": [
{
"type": "object",
"additionalProperties": false,
"required": ["left", "operator", "right"],
"properties": {
"left": { "$ref": "#/$defs/operand" },
"operator": { "enum": ["==", "!=", "<", "<=", ">", ">="] },
"right": { "$ref": "#/$defs/operand" }
}
},
{ "type": "object", "additionalProperties": false, "required": ["all"], "properties": { "all": { "type": "array", "minItems": 1, "items": { "$ref": "#/$defs/condition" } } } },
{ "type": "object", "additionalProperties": false, "required": ["any"], "properties": { "any": { "type": "array", "minItems": 1, "items": { "$ref": "#/$defs/condition" } } } },
{ "type": "object", "additionalProperties": false, "required": ["not"], "properties": { "not": { "$ref": "#/$defs/condition" } } }
]
}
},
"required": ["schemaVersion", "entrypoint"],
"properties": {
"schemaVersion": { "const": 1 },
"entrypoint": { "type": "string", "pattern": "^[^/\\\\](?!.*(?:^|[/\\\\])\\.\\.(?:[/\\\\]|$)).*\\.ink$" },
"ci": {
"type": "object",
"additionalProperties": false,
"properties": {
"maxDepth": { "type": "integer", "minimum": 1, "maximum": 1000 },
"maxStates": { "type": "integer", "minimum": 1, "maximum": 100000000 },
"goalMaxStates": { "type": "integer", "minimum": 0, "maximum": 100000000 },
"seed": { "type": "integer", "minimum": 1, "maximum": 4294967295 },
"storySeed": { "type": "integer", "minimum": 1, "maximum": 2147483646 },
"search": { "enum": ["portfolio", "shared", "shared-variable"] },
"concurrency": {
"oneOf": [
{ "const": "auto" },
{ "type": "integer", "minimum": 1, "maximum": 16 }
]
},
"maxMemoryMb": { "type": "integer", "minimum": 1, "maximum": 1000000 },
"maxTimeSec": { "type": "integer", "minimum": 1, "maximum": 86400 },
"maxFrontierStates": { "type": "integer", "minimum": 1, "maximum": 100000000 },
"maxFrontierMb": { "type": "integer", "minimum": 1, "maximum": 1000000 },
"strict": { "type": "boolean" },
"minRepro": { "type": "boolean" }
}
},
"assertions": {
"type": "array",
"items": {
"type": "object",
"additionalProperties": false,
"required": ["id", "when", "condition"],
"properties": {
"id": { "type": "string", "pattern": "^[a-z][a-z0-9_-]{0,63}$" },
"description": { "type": "string", "maxLength": 240 },
"when": {
"oneOf": [
{ "enum": ["always", "terminal"] },
{ "type": "object", "additionalProperties": false, "required": ["knot"], "properties": { "knot": { "type": "string" } } }
]
},
"condition": { "$ref": "#/$defs/condition" }
}
}
},
"goals": {
"type": "array",
"items": {
"type": "object",
"additionalProperties": false,
"required": ["id"],
"oneOf": [
{ "required": ["condition"], "not": { "required": ["stages"] } },
{ "required": ["stages"], "not": { "required": ["condition"] } }
],
"properties": {
"id": { "type": "string", "pattern": "^[a-z][a-z0-9_-]{0,63}$" },
"description": { "type": "string", "maxLength": 240 },
"condition": { "$ref": "#/$defs/condition" },
"stages": {
"type": "array",
"minItems": 2,
"items": {
"type": "object",
"additionalProperties": false,
"required": ["id", "condition"],
"properties": {
"id": { "type": "string", "pattern": "^[a-z][a-z0-9_-]{0,63}$" },
"description": { "type": "string", "maxLength": 240 },
"condition": { "$ref": "#/$defs/condition" }
}
}
}
}
}
}
}
}