Skip to content
File

Blob: build/deps/deps.schema.json

json255 lines
1{
2 "$schema": "https://json-schema.org/draft/2020-12/schema",
3 "$id": "https://example.com/product.schema.json",
4 "title": "Dependencies",
5 "description": "Description of external dependencies for the project",
6 "type": "object",
7 "properties": {
8 "repositories": {
9 "type": "array",
10 "items": {
11 "type": "object",
12 "oneOf": [
13 {
14 "type": "object",
15 "properties": {
16 "type": {
17 "const": "github_tarball"
18 },
19 "name": {
20 "type": "string"
21 },
22 "owner": {
23 "type": "string"
24 },
25 "repo": {
26 "type": "string"
27 },
28 "freeze_commit": {
29 "type": "string"
30 },
31 "freeze_sha256": {
32 "type": "string"
33 },
34 "build_file": {
35 "type": "string"
36 },
37 "build_file_content": {
38 "type": "string"
39 },
40 "patches": {
41 "type": "array",
42 "items": {
43 "type": "string"
44 }
45 },
46 "repo_mapping": {
47 "type": "object",
48 "additionalProperties": {
49 "type": "string"
50 }
51 },
52 "branch": {
53 "type": "string"
54 },
55 "extra_strip_prefix": {
56 "type": "string"
57 },
58 "use_bazel_dep": {
59 "type": "boolean"
60 },
61 "repo_name": {
62 "type": "string"
63 },
64 "use_module_bazel_from_bcr": {
65 "type": "string"
66 }
67 },
68 "required": [
69 "type",
70 "name",
71 "owner",
72 "repo"
73 ],
74 "additionalProperties": false
75 },
76 {
77 "type": "object",
78 "properties": {
79 "type": {
80 "const": "github_release"
81 },
82 "name": {
83 "type": "string"
84 },
85 "owner": {
86 "type": "string"
87 },
88 "repo": {
89 "type": "string"
90 },
91 "file_regex": {
92 "type": "string"
93 },
94 "file_type": {
95 "type": "string",
96 "enum": [
97 "archive",
98 "executable"
99 ]
100 },
101 "freeze_version": {
102 "type": "string"
103 },
104 "freeze_sha256": {
105 "type": "string"
106 },
107 "strip_prefix": {
108 "type": "string"
109 },
110 "build_file": {
111 "type": "string"
112 },
113 "build_file_content": {
114 "type": "string"
115 },
116 "patches": {
117 "type": "array",
118 "items": {
119 "type": "string"
120 }
121 },
122 "repo_mapping": {
123 "type": "object",
124 "additionalProperties": {
125 "type": "string"
126 }
127 },
128 "downloaded_file_path": {
129 "type": "string"
130 },
131 "use_bazel_dep": {
132 "type": "boolean"
133 },
134 "repo_name": {
135 "type": "string"
136 },
137 "use_module_bazel_from_bcr": {
138 "type": "string"
139 }
140 },
141 "required": [
142 "type",
143 "name",
144 "owner",
145 "repo"
146 ],
147 "additionalProperties": false
148 },
149 {
150 "type": "object",
151 "properties": {
152 "type": {
153 "const": "git_clone"
154 },
155 "name": {
156 "type": "string"
157 },
158 "url": {
159 "type": "string"
160 },
161 "branch": {
162 "type": "string"
163 },
164 "build_file": {
165 "type": "string"
166 },
167 "build_file_content": {
168 "type": "string"
169 },
170 "freeze_commit": {
171 "type": "string"
172 },
173 "patches": {
174 "type": "array",
175 "items": {
176 "type": "string"
177 }
178 },
179 "repo_mapping": {
180 "type": "object",
181 "additionalProperties": {
182 "type": "string"
183 }
184 },
185 "use_bazel_dep": {
186 "type": "boolean"
187 },
188 "repo_name": {
189 "type": "string"
190 }
191 },
192 "required": [
193 "type",
194 "name",
195 "url"
196 ],
197 "additionalProperties": false
198 },
199 {
200 "type": "object",
201 "properties": {
202 "type": {
203 "const": "crate"
204 },
205 "name": {
206 "type": "string"
207 },
208 "build_file": {
209 "type": "string"
210 },
211 "freeze_version": {
212 "type": "string"
213 }
214 },
215 "required": [
216 "type",
217 "name",
218 "build_file"
219 ],
220 "additionalProperties": false
221 },
222 {
223 "type": "object",
224 "properties": {
225 "type": {
226 "const": "bazel_dep"
227 },
228 "name": {
229 "type": "string"
230 },
231 "freeze_version": {
232 "type": "string"
233 },
234 "patches": {
235 "type": "array",
236 "items": {
237 "type": "string"
238 }
239 }
240 },
241 "required": [
242 "type",
243 "name"
244 ],
245 "additionalProperties": false
246 }
247 ]
248 }
249 }
250 },
251 "required": [
252 "repositories"
253 ]
254}