helix-mods/runtime/queries/bash/highlights.scm

70 lines
768 B
Scheme
Raw Normal View History

2021-04-09 10:42:49 +02:00
[
(string)
(raw_string)
(heredoc_body)
(heredoc_start)
] @string
(command_name) @function
(variable_name) @variable.other.member
2021-04-09 10:42:49 +02:00
[
"if"
"then"
"else"
"elif"
"fi"
2021-04-09 10:42:49 +02:00
"case"
"in"
"esac"
] @keyword.control.conditional
[
"for"
2021-04-09 10:42:49 +02:00
"do"
"done"
"select"
"until"
"while"
] @keyword.control.repeat
[
"declare"
"typeset"
2021-04-09 10:42:49 +02:00
"export"
"readonly"
"local"
2021-04-09 10:42:49 +02:00
"unset"
"unsetenv"
2021-04-09 10:42:49 +02:00
] @keyword
"function" @keyword.function
2021-04-09 10:42:49 +02:00
(comment) @comment
(function_definition name: (word) @function)
(file_descriptor) @constant.numeric.integer
2021-04-09 10:42:49 +02:00
[
(command_substitution)
(process_substitution)
(expansion)
]@embedded
[
"$"
"&&"
">"
">>"
"<"
"|"
2022-04-01 15:48:39 +02:00
(expansion_flags)
2021-04-09 10:42:49 +02:00
] @operator
(
(command (_) @constant)
(#match? @constant "^-")
)