Skip to content

Commit 7c18e57

Browse files
committed
Move the "booleanString" schema to the general definitions file
This is an enum that contains the supported string representations of Boolean values. It was previously used only by the boards.txt schema, and so was hosted in its file, but now there is a need for it in the platform.txt specification as well, so it goes in the file that holds the shared definitions.
1 parent f5274ec commit 7c18e57

File tree

3 files changed

+18
-18
lines changed

3 files changed

+18
-18
lines changed

etc/schemas/arduino-boards-txt-definitions-schema.json

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -773,7 +773,7 @@
773773
"type": "string"
774774
},
775775
{
776-
"$ref": "#/definitions/enumObjects/booleanString"
776+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
777777
}
778778
]
779779
}
@@ -814,7 +814,7 @@
814814
"type": "string"
815815
},
816816
{
817-
"$ref": "#/definitions/enumObjects/booleanString"
817+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
818818
}
819819
]
820820
}
@@ -1016,7 +1016,7 @@
10161016
"type": "string"
10171017
},
10181018
{
1019-
"$ref": "#/definitions/enumObjects/booleanString"
1019+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
10201020
}
10211021
]
10221022
}
@@ -1057,7 +1057,7 @@
10571057
"type": "string"
10581058
},
10591059
{
1060-
"$ref": "#/definitions/enumObjects/booleanString"
1060+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
10611061
}
10621062
]
10631063
}
@@ -1215,11 +1215,6 @@
12151215
}
12161216
}
12171217
}
1218-
},
1219-
"enumObjects": {
1220-
"booleanString": {
1221-
"enum": ["true", "false"]
1222-
}
12231218
}
12241219
}
12251220
}

etc/schemas/general-definitions-schema.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@
2323
"pattern": "^[aA][rR][dD][uU][iI][nN][oO].*$"
2424
}
2525
}
26+
},
27+
"enumObjects": {
28+
"booleanString": {
29+
"enum": ["true", "false"]
30+
}
2631
}
2732
}
2833
}

internal/rule/schema/schemadata/bindata.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -848,7 +848,7 @@ var _arduinoBoardsTxtDefinitionsSchemaJson = []byte(`{
848848
"type": "string"
849849
},
850850
{
851-
"$ref": "#/definitions/enumObjects/booleanString"
851+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
852852
}
853853
]
854854
}
@@ -889,7 +889,7 @@ var _arduinoBoardsTxtDefinitionsSchemaJson = []byte(`{
889889
"type": "string"
890890
},
891891
{
892-
"$ref": "#/definitions/enumObjects/booleanString"
892+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
893893
}
894894
]
895895
}
@@ -1091,7 +1091,7 @@ var _arduinoBoardsTxtDefinitionsSchemaJson = []byte(`{
10911091
"type": "string"
10921092
},
10931093
{
1094-
"$ref": "#/definitions/enumObjects/booleanString"
1094+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
10951095
}
10961096
]
10971097
}
@@ -1132,7 +1132,7 @@ var _arduinoBoardsTxtDefinitionsSchemaJson = []byte(`{
11321132
"type": "string"
11331133
},
11341134
{
1135-
"$ref": "#/definitions/enumObjects/booleanString"
1135+
"$ref": "general-definitions-schema.json#/definitions/enumObjects/booleanString"
11361136
}
11371137
]
11381138
}
@@ -1290,11 +1290,6 @@ var _arduinoBoardsTxtDefinitionsSchemaJson = []byte(`{
12901290
}
12911291
}
12921292
}
1293-
},
1294-
"enumObjects": {
1295-
"booleanString": {
1296-
"enum": ["true", "false"]
1297-
}
12981293
}
12991294
}
13001295
}
@@ -6175,6 +6170,11 @@ var _generalDefinitionsSchemaJson = []byte(`{
61756170
"pattern": "^[aA][rR][dD][uU][iI][nN][oO].*$"
61766171
}
61776172
}
6173+
},
6174+
"enumObjects": {
6175+
"booleanString": {
6176+
"enum": ["true", "false"]
6177+
}
61786178
}
61796179
}
61806180
}

0 commit comments

Comments
 (0)