12345678910111213141516171819202122232425262728293031323334 |
- %YAML 1.2
- ---
- # See http://www.sublimetext.com/docs/3/syntax.html
- name: Numbat
- file_extensions:
- - nbt
- scope: source.nbt
- contexts:
- main:
- - match: \b(per|to|let|fn|where|and|dimension|unit|use|struct|long|short|both|none|if|then|else|true|false|print|assert|assert_eq|type)\b
- scope: keyword.control.nbt
- - match: '#(.*)'
- scope: comment.line.nbt
- - match: \b([0-9][0-9_]*(\.[0-9][0-9_]*)?(e[+\-]?[0-9]+)?|0b[01]+|0o[0-7]+|0x[0-9a-fA-F]+|NaN|inf)\b
- scope: constant.numeric.nbt
- - match: \b([A-Z][a-zA-Z]*)\b
- scope: storage.type.nbt
- - match: \b([a-z][a-zA-Z_0-9]*)\b
- scope: variable.other.nbt
- - match: '(@aliases|@metric_prefixes|@binary_prefixes|@name|@url)'
- scope: meta.annotation.attribute.nbt
- - match: '[+\-/*=\^:<>·×÷²³]'
- scope: keyword.operator.nbt
- - match: '[\(\)]'
- scope: punctuation.definition.parenthesis.nbt
- - match: ','
- scope: punctuation.separator.comma.nbt
- - match: '"'
- scope: punctuation.definition.string.begin.nbt
- push:
- - meta_scope: string.quoted.double.nbt
- - match: '"'
- scope: punctuation.definition.string.end.nbt
- pop: true
|