feat(cli): generate json schemas locally

This commit updates the various komorebic json schema generation
commands to generate the schemas locally, without requiring a running
instance of komorebi to communicate with over IPC.
This commit is contained in:
LGUG2Z
2024-09-18 10:59:22 -07:00
parent 96d094d9d7
commit df19d06333
6 changed files with 46 additions and 36 deletions

View File

@@ -19,7 +19,7 @@
"null"
],
"items": {
"$ref": "#/definitions/IdWithIdentifierAndComment"
"$ref": "#/definitions/MatchingRule"
}
},
"identifier": {
@@ -53,9 +53,9 @@
"enum": [
"object_name_change",
"layered",
"border_overflow",
"tray_and_multi_window",
"force"
"force",
"border_overflow"
]
},
"IdWithIdentifier": {
@@ -83,36 +83,18 @@
}
}
},
"IdWithIdentifierAndComment": {
"type": "object",
"required": [
"id",
"kind"
],
"properties": {
"comment": {
"type": [
"string",
"null"
]
"MatchingRule": {
"anyOf": [
{
"$ref": "#/definitions/IdWithIdentifier"
},
"id": {
"type": "string"
},
"kind": {
"$ref": "#/definitions/ApplicationIdentifier"
},
"matching_strategy": {
"anyOf": [
{
"$ref": "#/definitions/MatchingStrategy"
},
{
"type": "null"
}
]
{
"type": "array",
"items": {
"$ref": "#/definitions/IdWithIdentifier"
}
}
}
]
},
"MatchingStrategy": {
"type": "string",
@@ -122,7 +104,11 @@
"StartsWith",
"EndsWith",
"Contains",
"Regex"
"Regex",
"DoesNotEndWith",
"DoesNotStartWith",
"DoesNotEqual",
"DoesNotContain"
]
}
}