mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-05 00:15:32 +00:00
chore: update kmp.schema.json and docs for kps schema
This commit is contained in:
parent
a22746e984
commit
fae6277b20
3 changed files with 393 additions and 3 deletions
24
common/schemas/kmp/README.md
Normal file
24
common/schemas/kmp/README.md
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
# kmp.schema.json
|
||||
|
||||
* kmp.json file format, metadata included in Keyman .kmp package files
|
||||
|
||||
Documentation at https://help.keyman.com/developer/current-version/reference/file-types/metadata
|
||||
|
||||
# kmp.schema.json version history
|
||||
|
||||
## 2023-10-19 2.0
|
||||
* Add relatedPackages, options.licenseFile, options.welcomeFile,
|
||||
keyboard.examples, keyboard.webOskFonts, keyboard.webDisplayFonts,
|
||||
info.description (all of these formerly were stored in .keyboard_info)
|
||||
|
||||
## 2019-01-31 1.1.0
|
||||
* Add lexicalModels properties (note: `version` is optional and currently unused)
|
||||
|
||||
## 2018-02-13 1.0.2
|
||||
* Add rtl property for keyboard layouts
|
||||
|
||||
## 2018-01-22 1.0.1
|
||||
* Remove id field as it is derived from the filename anyway
|
||||
|
||||
## 2017-11-30 1.0 beta
|
||||
* Initial version
|
||||
353
common/schemas/kmp/kmp.schema.json
Normal file
353
common/schemas/kmp/kmp.schema.json
Normal file
|
|
@ -0,0 +1,353 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/schema#",
|
||||
"$ref": "#/definitions/package",
|
||||
"definitions": {
|
||||
"package": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"system": {
|
||||
"$ref": "#/definitions/system"
|
||||
},
|
||||
"options": {
|
||||
"$ref": "#/definitions/options"
|
||||
},
|
||||
"startMenu": {
|
||||
"$ref": "#/definitions/startMenu"
|
||||
},
|
||||
"strings": {
|
||||
"$ref": "#/definitions/strings"
|
||||
},
|
||||
"files": {
|
||||
"$ref": "#/definitions/files"
|
||||
},
|
||||
"keyboards": {
|
||||
"$ref": "#/definitions/keyboards"
|
||||
},
|
||||
"lexicalModels": {
|
||||
"$ref": "#/definitions/lexicalModels"
|
||||
},
|
||||
"info": {
|
||||
"$ref": "#/definitions/info"
|
||||
},
|
||||
"relatedPackages": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/relatedPackage"
|
||||
}
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"options",
|
||||
"system"
|
||||
]
|
||||
},
|
||||
"system": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"keymanDeveloperVersion": {
|
||||
"type": "string"
|
||||
},
|
||||
"fileVersion": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"fileVersion"
|
||||
]
|
||||
},
|
||||
"options": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"readmeFile": {
|
||||
"type": "string"
|
||||
},
|
||||
"graphicFile": {
|
||||
"type": "string"
|
||||
},
|
||||
"licenseFile": {
|
||||
"type": "string"
|
||||
},
|
||||
"welcomeFile": {
|
||||
"type": "string"
|
||||
},
|
||||
"executeProgram": {
|
||||
"type": "string"
|
||||
},
|
||||
"msiFilename": {
|
||||
"type": "string"
|
||||
},
|
||||
"msiOptions": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"startMenu": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"folder": {
|
||||
"type": "string"
|
||||
},
|
||||
"addUninstallEntry": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/startMenuItem"
|
||||
}
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"startMenuItem": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"filename": {
|
||||
"type": "string"
|
||||
},
|
||||
"arguments": {
|
||||
"type": "string"
|
||||
},
|
||||
"icon": {
|
||||
"type": "string"
|
||||
},
|
||||
"location": {
|
||||
"type": "number"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"name",
|
||||
"filename"
|
||||
]
|
||||
},
|
||||
"strings": {
|
||||
"type": "object",
|
||||
"patternProperties": {
|
||||
".": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"files": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/file"
|
||||
}
|
||||
},
|
||||
"file": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": {
|
||||
"type": "string"
|
||||
},
|
||||
"copyLocation": {
|
||||
"type": "number"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"name",
|
||||
"description"
|
||||
]
|
||||
},
|
||||
"keyboards": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/keyboard"
|
||||
}
|
||||
},
|
||||
"keyboard": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"version": {
|
||||
"type": "string"
|
||||
},
|
||||
"oskFont": {
|
||||
"type": "string"
|
||||
},
|
||||
"displayFont": {
|
||||
"type": "string"
|
||||
},
|
||||
"rtl": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"languages": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/keyboardLanguage"
|
||||
}
|
||||
},
|
||||
"examples": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/keyboardExample"
|
||||
}
|
||||
},
|
||||
"webOskFonts": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"webDisplayFonts": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"name",
|
||||
"id",
|
||||
"version"
|
||||
]
|
||||
},
|
||||
"keyboardLanguage": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"id",
|
||||
"name"
|
||||
]
|
||||
},
|
||||
"info": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"website": {
|
||||
"$ref": "#/definitions/infoItem"
|
||||
},
|
||||
"version": {
|
||||
"$ref": "#/definitions/infoItem"
|
||||
},
|
||||
"name": {
|
||||
"$ref": "#/definitions/infoItem"
|
||||
},
|
||||
"copyright": {
|
||||
"$ref": "#/definitions/infoItem"
|
||||
},
|
||||
"author": {
|
||||
"$ref": "#/definitions/infoItem"
|
||||
},
|
||||
"description": {
|
||||
"$ref": "#/definitions/infoItem"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
},
|
||||
"infoItem": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"description": {
|
||||
"type": "string"
|
||||
},
|
||||
"url": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"description"
|
||||
]
|
||||
},
|
||||
"lexicalModels": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/lexicalModel"
|
||||
}
|
||||
},
|
||||
"lexicalModel": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"version": {
|
||||
"type": "string"
|
||||
},
|
||||
"rtl": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"languages": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/keyboardLanguage"
|
||||
}
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"name",
|
||||
"id",
|
||||
"languages"
|
||||
]
|
||||
},
|
||||
"keyboardExample": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"keys": {
|
||||
"type": "string"
|
||||
},
|
||||
"text": {
|
||||
"type": "string"
|
||||
},
|
||||
"note": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"id",
|
||||
"keys"
|
||||
]
|
||||
},
|
||||
"relatedPackage": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"relationship": {
|
||||
"type": "string",
|
||||
"enum": ["deprecates", "related"]
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"id",
|
||||
"relationship"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1,9 +1,22 @@
|
|||
# kps.xsd
|
||||
|
||||
Master version: https://github.com/keymanapp/api.keyman.com/blob/master/schemas/kps/7.0/kps.xsd
|
||||
Master version: https://github.com/keymanapp/api.keyman.com/blob/master/schemas/kps/17.0/kps.xsd
|
||||
|
||||
## 2023-10-19 17.0
|
||||
* Version 17.0 adds:
|
||||
- LicenseFile - a .md file, usually named LICENSE.md
|
||||
- WelcomeFile - a .htm file, usually named welcome.htm (later versions will support .md)
|
||||
- Info/Description - a short Markdown description of the content of the package, e.g. shown in search results on keyman.com
|
||||
- RelatedPackages - a list of other packages which relate to this one, or are deprecated by it
|
||||
- Keyboards/Keyboard/Examples - a list of typing examples for the keyboard
|
||||
- Keyboarsd/Keyboard/WebOSKFonts - a list of font filenames (not necessarily in package) suitable for rendering the on screen keyboard
|
||||
- Keyboarsd/Keyboard/WebDisplayFonts - a list of font filenames (not necessarily in package) suitable for use with the keyboard
|
||||
* Version 17.0 removes:
|
||||
- LexicalModels/LexicalModel/Version - version information is not stored in the models, but only in the package metadata (was unused)
|
||||
|
||||
## 2023-04-21 7.0.1
|
||||
* Removes LexicalModel.Version, as it was never read or written
|
||||
|
||||
## 2021-07-19 7.0
|
||||
* Initial version 7.0
|
||||
|
||||
## 2023-04-21 7.0.1
|
||||
* Removes LexicalModel.Version, as it was never read or written
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue