mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-11 07:50:07 -04:00
add(vim): add highlight for more keywords
This commit is contained in:
parent
6bc17444fb
commit
c867d483a5
1 changed files with 18 additions and 1 deletions
|
|
@ -59,6 +59,7 @@
|
||||||
"setlocal"
|
"setlocal"
|
||||||
"silent"
|
"silent"
|
||||||
"echo"
|
"echo"
|
||||||
|
"echomsg"
|
||||||
"autocmd"
|
"autocmd"
|
||||||
"augroup"
|
"augroup"
|
||||||
"return"
|
"return"
|
||||||
|
|
@ -70,6 +71,12 @@
|
||||||
"highlight"
|
"highlight"
|
||||||
"delcommand"
|
"delcommand"
|
||||||
"comclear"
|
"comclear"
|
||||||
|
"colorscheme"
|
||||||
|
"startinsert"
|
||||||
|
"stopinsert"
|
||||||
|
"global"
|
||||||
|
"runtime"
|
||||||
|
"wincmd"
|
||||||
] @keyword
|
] @keyword
|
||||||
(map_statement cmd: _ @keyword)
|
(map_statement cmd: _ @keyword)
|
||||||
(command_name) @function.macro
|
(command_name) @function.macro
|
||||||
|
|
@ -121,13 +128,23 @@
|
||||||
"clear"
|
"clear"
|
||||||
] @keyword)
|
] @keyword)
|
||||||
|
|
||||||
|
;; Runtime command
|
||||||
|
|
||||||
|
(runtime_statement (where) @keyword.operator)
|
||||||
|
|
||||||
|
;; Colorscheme command
|
||||||
|
|
||||||
|
(colorscheme_statement (name) @string)
|
||||||
|
|
||||||
;; Literals
|
;; Literals
|
||||||
|
|
||||||
(string_literal) @string
|
(string_literal) @string
|
||||||
(integer_literal) @number
|
(integer_literal) @number
|
||||||
(float_literal) @float
|
(float_literal) @float
|
||||||
(comment) @comment
|
(comment) @comment
|
||||||
(pattern) @string.special
|
(pattern
|
||||||
|
(pattern_multi) @string.regex) @string.special
|
||||||
|
(filename) @string
|
||||||
((scoped_identifier
|
((scoped_identifier
|
||||||
(scope) @_scope . (identifier) @boolean)
|
(scope) @_scope . (identifier) @boolean)
|
||||||
(#eq? @_scope "v:")
|
(#eq? @_scope "v:")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue