diff options
| author | Amaan Qureshi <amaanq12@gmail.com> | 2023-08-24 17:12:10 -0400 |
|---|---|---|
| committer | Amaan Qureshi <amaanq12@gmail.com> | 2023-08-24 17:17:53 -0400 |
| commit | ed2c6da5a0959d5c0462ef64ac08d3faa4e92861 (patch) | |
| tree | 75576629dd0b693222df5b8aae89d1fb96ed5639 /queries/bash | |
| parent | feat(bash): fold heredocs (diff) | |
| download | nvim-treesitter-ed2c6da5a0959d5c0462ef64ac08d3faa4e92861.tar nvim-treesitter-ed2c6da5a0959d5c0462ef64ac08d3faa4e92861.tar.gz nvim-treesitter-ed2c6da5a0959d5c0462ef64ac08d3faa4e92861.tar.bz2 nvim-treesitter-ed2c6da5a0959d5c0462ef64ac08d3faa4e92861.tar.lz nvim-treesitter-ed2c6da5a0959d5c0462ef64ac08d3faa4e92861.tar.xz nvim-treesitter-ed2c6da5a0959d5c0462ef64ac08d3faa4e92861.tar.zst nvim-treesitter-ed2c6da5a0959d5c0462ef64ac08d3faa4e92861.zip | |
feat(bash): add missing highlights
Diffstat (limited to 'queries/bash')
| -rw-r--r-- | queries/bash/highlights.scm | 39 |
1 files changed, 32 insertions, 7 deletions
diff --git a/queries/bash/highlights.scm b/queries/bash/highlights.scm index dbe6f6883..8cc84194c 100644 --- a/queries/bash/highlights.scm +++ b/queries/bash/highlights.scm @@ -3,11 +3,14 @@ "{" "}" "[" "]" "[[" "]]" + "((" "))" ] @punctuation.bracket [ ";" ";;" + ";&" + ";;&" "&" ] @punctuation.delimiter @@ -18,11 +21,24 @@ "<<" "&&" "|" + "|&" "||" "=" + "+=" "=~" "==" "!=" + + "&>" + "&>>" + "<&" + ">&" + ">|" + + "<<-" + "<<<" + + ".." ] @operator ; Do *not* spell check strings since they typically have some sort of @@ -42,6 +58,7 @@ ] @label (variable_assignment (word) @string) +(command argument: "$" @string) ; bare dollar [ "if" @@ -64,11 +81,13 @@ ] @repeat [ - "declare" - "export" - "local" - "readonly" - "unset" + "declare" + "typeset" + "export" + "readonly" + "local" + "unset" + "unsetenv" ] @keyword "function" @keyword.function @@ -129,9 +148,10 @@ (#lua-match? @number "^[0-9]+$")) (file_redirect - descriptor: (file_descriptor) @operator destination: (word) @parameter) +(file_descriptor) @operator + (simple_expansion "$" @punctuation.special) @none (expansion @@ -146,6 +166,8 @@ index: (word) @character.special)) (#any-of? @character.special "@" "*")) +"``" @punctuation.special + (variable_name) @variable ((variable_name) @constant @@ -154,7 +176,10 @@ (case_item value: (word) @parameter) -(regex) @string.regex +[ + (regex) + (extglob_pattern) +] @string.regex ((program . (comment) @preproc) (#lua-match? @preproc "^#!/")) |
