Files
vscode/extensions/yaml/syntaxes/yaml.tmLanguage.json
2024-08-06 08:26:38 -07:00

106 lines
2.9 KiB
JSON
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{
"information_for_contributors": [
"This file has been converted from https://github.com/RedCMD/YAML-Syntax-Highlighter/blob/master/syntaxes/yaml.tmLanguage.json",
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
"Once accepted there, we are happy to receive an update request."
],
"version": "https://github.com/RedCMD/YAML-Syntax-Highlighter/commit/d4dca9f38a654ebbb13c1b72b7881e3c5864a778",
"name": "YAML Ain't Markup Language",
"scopeName": "source.yaml",
"patterns": [
{
"comment": "Support legacy FrontMatter integration",
"//": "https://github.com/microsoft/vscode-markdown-tm-grammar/pull/162",
"begin": "(?<=^-{3,}\\s*+)\\G$",
"while": "^(?! {3,0}-{3,}[ \t]*+$|[ \t]*+\\.{3}$)",
"patterns": [
{
"include": "source.yaml.1.2"
}
]
},
{
"comment": "Default to YAML version 1.2",
"include": "source.yaml.1.2"
}
],
"repository": {
"parity": {
"comment": "Yes... That is right. Due to the changes with \\x2028, \\x2029, \\x85 and 'tags'. This is all the code I was able to reuse between all YAML versions 1.3, 1.2, 1.1 and 1.0"
},
"block-map-key-single": {
"comment": "https://yaml.org/spec/1.2.2/#rule-c-single-quoted (BLOCK-KEY)",
"begin": "\\G'",
"end": "'(?!')",
"beginCaptures": {
"0": {
"name": "punctuation.definition.string.begin.yaml"
}
},
"endCaptures": {
"0": {
"name": "punctuation.definition.string.end.yaml"
}
},
"name": "meta.map.key.yaml string.quoted.single.yaml entity.name.tag.yaml",
"patterns": [
{
"match": ".[\t ]*+$",
"name": "invalid.illegal.multiline-key.yaml"
},
{
"match": "[^\t -\\x{10FFFF}]++",
"name": "invalid.illegal.character.yaml"
},
{
"match": "''",
"name": "constant.character.escape.single-quote.yaml"
}
]
},
"key-single": {
"comment": "https://yaml.org/spec/1.2.2/#rule-c-single-quoted (FLOW-OUT)",
"begin": "'",
"end": "'(?!')",
"beginCaptures": {
"0": {
"name": "punctuation.definition.string.begin.yaml"
}
},
"endCaptures": {
"0": {
"name": "punctuation.definition.string.end.yaml"
}
},
"name": "meta.map.key.yaml string.quoted.single.yaml entity.name.tag.yaml",
"patterns": [
{
"match": "[^\t -\\x{10FFFF}]++",
"name": "invalid.illegal.character.yaml"
},
{
"match": "''",
"name": "constant.character.escape.single-quote.yaml"
}
]
},
"non-printable": {
"//": {
"85": "…",
"2028": "",
"2029": "",
"10000": "𐀀",
"A0": " ",
"D7FF": "퟿",
"E000": "",
"FFFD": "<22>",
"FEFF": "",
"FFFF": "￿",
"10FFFF": "􏿿"
},
"//match": "[\\p{Cntrl}\\p{Surrogate}\\x{FFFE FFFF}&&[^\t\n\r\\x{85}]]++",
"match": "[^\t\n\r -~\\x{85}\\x{A0}-\\x{D7FF}\\x{E000}-\\x{FFFD}\\x{010000}-\\x{10FFFF}]++",
"name": "invalid.illegal.non-printable.yaml"
}
}
}