micro/runtime/syntax/nix.yaml
vandervoortj 9ceb69921a
Add nix language syntax (#2024)
* Create nix.yaml

Add nix language syntax

* Add nix-linter
2021-06-15 17:56:31 -04:00

28 lines
598 B
YAML

filetype: nix
detect:
filename: "\\.nix$"
rules:
- special: "\\b(Ellipsis|null|self|super|true|false|abort)\\b"
- statement: "\\b(let|in|with|import|rec|inherit)\\b"
- symbol.operator: "([~^.:;,+*|=!\\%@]|<|>|/|-|&)"
- symbol.brackets: "([(){}]|\\[|\\])"
- constant.number: "\\b[0-9](_?[0-9])*(\\.([0-9](_?[0-9])*)?)?(e[0-9](_?[0-9])*)?\\b"
- constant.string:
start: "\""
end: "\""
rules: []
- constant.string:
start: "''"
end: "''"
rules: []
- comment:
start: "#"
end: "$"
rules: []