fix(fish): update for upstream changes

https://github.com/ram02z/tree-sitter-fish/pull/16

Co-authored-by: taekwombo <taekwombo@users.noreply.github.com>
This commit is contained in:
Stephan Seitz 2022-11-24 01:23:08 +01:00
parent 554260cdbe
commit b79c763c03

View file

@ -7,15 +7,21 @@
"||" "||"
"|" "|"
"&" "&"
"="
"!="
".." ".."
"!" "!"
(direction) (direction)
(stream_redirect) (stream_redirect)
(test_option)
] @operator ] @operator
; match operators of test command
(command
name: (word) @function (#match? @function "^test$")
argument: (word) @operator (#match? @operator "^(!?\\=|-[a-zA-Z]+)$"))
;; match operators of [ command
(test_command
argument: (word) @operator (#match? @operator "^(!?\\=|-[a-zA-Z]+)$"))
[ [
"not" "not"
"and" "and"
@ -103,7 +109,7 @@
] ]
) )
(command_substitution_dollar "$" @punctuation.bracket) (command_substitution "$" @punctuation.bracket)
; non-bultin command names ; non-bultin command names
(command name: (word) @function.call) (command name: (word) @function.call)
@ -116,7 +122,7 @@
] ]
) )
(test_command "test" @function.builtin) (test_command (word) @function.builtin)
;; Functions ;; Functions
@ -150,7 +156,6 @@
[(integer) (float)] @number [(integer) (float)] @number
(comment) @comment (comment) @comment
(comment) @spell (comment) @spell
(test_option) @string
((word) @boolean ((word) @boolean
(#any-of? @boolean "true" "false")) (#any-of? @boolean "true" "false"))