2020-06-22 17:39:54 -04:00
|
|
|
[
|
|
|
|
|
"("
|
|
|
|
|
")"
|
|
|
|
|
"{"
|
|
|
|
|
"}"
|
|
|
|
|
"["
|
|
|
|
|
"]"
|
|
|
|
|
] @punctuation.bracket
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
";"
|
|
|
|
|
";;"
|
|
|
|
|
(heredoc_start)
|
|
|
|
|
] @punctuation.delimiter
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
">"
|
|
|
|
|
"<"
|
|
|
|
|
"&"
|
|
|
|
|
"&&"
|
|
|
|
|
"|"
|
|
|
|
|
"||"
|
|
|
|
|
"="
|
|
|
|
|
"=="
|
|
|
|
|
"!="
|
|
|
|
|
] @operator
|
|
|
|
|
|
|
|
|
|
[
|
2020-08-16 11:24:10 -05:00
|
|
|
(string)
|
2020-06-22 17:39:54 -04:00
|
|
|
(raw_string)
|
|
|
|
|
(heredoc_body)
|
|
|
|
|
] @string
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
"if"
|
|
|
|
|
"then"
|
|
|
|
|
"else"
|
|
|
|
|
"elif"
|
|
|
|
|
"fi"
|
|
|
|
|
"case"
|
|
|
|
|
"in"
|
|
|
|
|
"esac"
|
|
|
|
|
] @conditional
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
"for"
|
|
|
|
|
"do"
|
|
|
|
|
"done"
|
|
|
|
|
"while"
|
|
|
|
|
] @repeat
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
"declare"
|
|
|
|
|
"export"
|
|
|
|
|
"local"
|
|
|
|
|
"readonly"
|
|
|
|
|
"unset"
|
|
|
|
|
] @keyword
|
|
|
|
|
|
|
|
|
|
[
|
2020-08-16 11:24:10 -05:00
|
|
|
(special_variable_name)
|
2020-06-22 17:39:54 -04:00
|
|
|
("$" (special_variable_name))
|
|
|
|
|
] @constant
|
|
|
|
|
|
|
|
|
|
((word) @constant
|
2020-08-16 11:24:10 -05:00
|
|
|
(#vim-match? @constant "SIG(INT|TERM|QUIT|TIN|TOU|STP|HUP)"))
|
2020-06-22 17:39:54 -04:00
|
|
|
|
|
|
|
|
((word) @boolean
|
2020-08-16 11:24:10 -05:00
|
|
|
(#vim-match? @boolean "true|false"))
|
2020-06-22 17:39:54 -04:00
|
|
|
|
|
|
|
|
((word) @number
|
2020-08-16 11:24:10 -05:00
|
|
|
(#vim-match? @number "^\d*$"))
|
2020-06-22 17:39:54 -04:00
|
|
|
|
|
|
|
|
(comment) @comment
|
2020-09-06 17:58:32 +02:00
|
|
|
(test_operator) @string
|
2020-06-22 17:39:54 -04:00
|
|
|
|
|
|
|
|
(command_substitution
|
|
|
|
|
[ "$(" ")" ] @punctuation.bracket)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(function_definition
|
|
|
|
|
name: (word) @function)
|
|
|
|
|
|
|
|
|
|
(command_name (word)) @function
|
|
|
|
|
|
2020-08-16 11:24:10 -05:00
|
|
|
(command
|
2020-06-22 17:39:54 -04:00
|
|
|
argument: [
|
|
|
|
|
(word) @parameter
|
|
|
|
|
((word) @number
|
2020-08-16 11:24:10 -05:00
|
|
|
(#vim-match? @number "^\d*$"))
|
2020-06-22 17:39:54 -04:00
|
|
|
(concatenation (word) @parameter)
|
|
|
|
|
])
|
|
|
|
|
|
|
|
|
|
(file_redirect
|
|
|
|
|
descriptor: (file_descriptor) @operator
|
|
|
|
|
destination: (word) @parameter)
|
|
|
|
|
|
|
|
|
|
|
2020-09-07 18:14:54 +02:00
|
|
|
("$" (variable_name)) @variable
|
2020-06-22 17:39:54 -04:00
|
|
|
|
2020-08-16 11:24:10 -05:00
|
|
|
(expansion
|
2020-06-22 17:39:54 -04:00
|
|
|
[ "${" "}" ] @punctuation.bracket)
|
|
|
|
|
|
2020-09-07 18:14:54 +02:00
|
|
|
(variable_name) @variable
|
2020-06-22 17:39:54 -04:00
|
|
|
|
2020-08-16 11:24:10 -05:00
|
|
|
(case_item
|
2020-06-22 17:39:54 -04:00
|
|
|
value: (word) @parameter)
|
|
|
|
|
|
|
|
|
|
(concatenation (word) @parameter)
|
|
|
|
|
|