-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathKSP configuration.JSON-tmLanguage
64 lines (64 loc) · 2.5 KB
/
KSP configuration.JSON-tmLanguage
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
// [PackageDev] target_format: plist, ext: tmLanguage
{
"name": "KSP configuration",
"scopeName": "text.ksp.cfg",
"fileTypes": ["cfg", "craft", "sfs"],
"uuid": "2e22ffdc-c42e-4308-819d-c125852f1fb7",
"patterns": [
{
"name": "comment.ksp.cfg",
"match": "//.*",
"comment": "Anything after 2 slashes is a comment."
},
{
"name": "variable.parameter.ksp.cfg",
"match": "(?<=[\\|\\[])([A-Za-z0-9\\*_]*)(?=[\\]\\|])",
"comment": "Alphanumeric characters inside square brackets is a parameter."
},
{
"name": "support.function.modulemanager.ksp.cfg",
"match": "(?<=:)([A-Za-z0-9]*)",
"comment": "Alphanumeric characters after a colon is a ModuleManager function."
},
{
"name": "keyword.ksp.cfg",
"match": "([A-Za-z0-9_,]*\\s*)(?=([\\*\\+])?=)",
"comment": "Anything before an equal sign is a key in the key-value pairs."
},
{
"name": "constant.numeric.pid.ksp.cfg",
"match": "(?<==)(\\s*[0-9a-f]{32})",
"comment": "32 hexadecimal characters after an equal sign is a pid."
},
{
"name": "constant.numeric.guid.ksp.cfg",
"match": "(?<==)(\\s*([a-z0-9]+\\-){4}[a-z0-9]+)",
"comment": "Alphanumeric characters split by 4 hyphens after an equal sign is a guid."
},
{
"name": "constant.numeric.boolean.ksp.cfg",
"match": "(?<==)(\\s*([Tt]rue|[Ff]alse))",
"comment": "'True' or 'False' after an equal sign is a boolean."
},
{
"name": "constant.numeric.nan.ksp.cfg",
"match": "(?<==)(\\s*(NaN|Infinity|None))",
"comment": "'NaN', 'Infinity', or 'None' after an equal sign is a non-numeric constant."
},
{
"name": "string.ksp.cfg",
"match": "(?<==)(\\s?.*[A-Za-z].*)",
"comment": "Anything else after an equal sign containing alphabetical characters is a string."
},
{
"name": "constant.numeric.ksp.cfg",
"match": "(?<=[=,\\s\\(])(\\s*-?[0-9\\.]+E?-?[0-9\\.]*)",
"comment": "Numeric characters, including scientific notation, is a number."
},
{
"name": "entity.name.class.ksp.cfg",
"match": "[A-Za-z0-9\\*_\\./]*",
"comment": "Anything else matching these symbols is a class name."
}
]
}