Skip to content

Commit 9e2280a

Browse files
committed
Patch schema to make remotes in the project required
1 parent 1b3fabf commit 9e2280a

File tree

5 files changed

+46
-8
lines changed

5 files changed

+46
-8
lines changed

schema-transformation-rules/devworkspace/addRequiredFields.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,19 @@
2323
"op": "add",
2424
"path": "/properties/spec/properties/components/items/properties/openshift/properties/endpoints/items/required/-",
2525
"value": "targetPort"
26+
},
27+
{
28+
"op": "add",
29+
"path": "/properties/spec/properties/projects/items/properties/git/required",
30+
"value": [
31+
"remotes"
32+
]
33+
},
34+
{
35+
"op": "add",
36+
"path": "/properties/spec/properties/projects/items/properties/github/required",
37+
"value": [
38+
"remotes"
39+
]
2640
}
2741
]

schemas/devfile.json

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3574,7 +3574,10 @@
35743574
},
35753575
"type": "object",
35763576
"markdownDescription": "Project's Git source",
3577-
"additionalProperties": false
3577+
"additionalProperties": false,
3578+
"required": [
3579+
"remotes"
3580+
]
35783581
},
35793582
"github": {
35803583
"description": "Project's GitHub source",
@@ -3613,7 +3616,10 @@
36133616
},
36143617
"type": "object",
36153618
"markdownDescription": "Project's GitHub source",
3616-
"additionalProperties": false
3619+
"additionalProperties": false,
3620+
"required": [
3621+
"remotes"
3622+
]
36173623
},
36183624
"name": {
36193625
"description": "Project name",

schemas/devworkspace-template-spec.json

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3973,7 +3973,10 @@
39733973
},
39743974
"type": "object",
39753975
"markdownDescription": "Project's Git source",
3976-
"additionalProperties": false
3976+
"additionalProperties": false,
3977+
"required": [
3978+
"remotes"
3979+
]
39773980
},
39783981
"github": {
39793982
"description": "Project's GitHub source",
@@ -4012,7 +4015,10 @@
40124015
},
40134016
"type": "object",
40144017
"markdownDescription": "Project's GitHub source",
4015-
"additionalProperties": false
4018+
"additionalProperties": false,
4019+
"required": [
4020+
"remotes"
4021+
]
40164022
},
40174023
"name": {
40184024
"description": "Project name",

schemas/devworkspace-template.json

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3990,7 +3990,10 @@
39903990
},
39913991
"type": "object",
39923992
"markdownDescription": "Project's Git source",
3993-
"additionalProperties": false
3993+
"additionalProperties": false,
3994+
"required": [
3995+
"remotes"
3996+
]
39943997
},
39953998
"github": {
39963999
"description": "Project's GitHub source",
@@ -4029,7 +4032,10 @@
40294032
},
40304033
"type": "object",
40314034
"markdownDescription": "Project's GitHub source",
4032-
"additionalProperties": false
4035+
"additionalProperties": false,
4036+
"required": [
4037+
"remotes"
4038+
]
40334039
},
40344040
"name": {
40354041
"description": "Project name",

schemas/devworkspace.json

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3999,7 +3999,10 @@
39993999
},
40004000
"type": "object",
40014001
"markdownDescription": "Project's Git source",
4002-
"additionalProperties": false
4002+
"additionalProperties": false,
4003+
"required": [
4004+
"remotes"
4005+
]
40034006
},
40044007
"github": {
40054008
"description": "Project's GitHub source",
@@ -4038,7 +4041,10 @@
40384041
},
40394042
"type": "object",
40404043
"markdownDescription": "Project's GitHub source",
4041-
"additionalProperties": false
4044+
"additionalProperties": false,
4045+
"required": [
4046+
"remotes"
4047+
]
40424048
},
40434049
"name": {
40444050
"description": "Project name",

0 commit comments

Comments
 (0)