Update treesitter highlight groups + remove syntax error highlights (#232)

* Ignore highlight groups from the default treesitter config

https://github.com/nvim-treesitter/nvim-treesitter/blob/master/plugin/nvim-treesitter.vim

* Remove TSError highlight

I mistakenly thought the TSError highlight group was used for
highlighting error types. However upon further investigation into
https://github.com/dracula/vim/issues/231 I discovered it's actually
applied to syntax errors.

While typing out new code, treesitter is unable to parse the new code
and will highlight with TSError, in most cases we don't want that to
show up as an Error since we're not finished typing. See
https://github.com/nvim-treesitter/nvim-treesitter/issues/78#issuecomment-647140700
for more infomation.
This commit is contained in:
Derek Stride 2021-03-08 16:17:28 -03:30 committed by GitHub
parent 32f0a489d1
commit 561c21a962
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -44,62 +44,31 @@ endif
" Tree-sitter: {{{ " Tree-sitter: {{{
if exists('g:loaded_nvim_treesitter') if exists('g:loaded_nvim_treesitter')
" # Misc " # Misc
hi! link TSError ErrorMsg
hi! link TSPunctDelimiter Delimiter
hi! link TSPunctBracket Normal
hi! link TSPunctSpecial Special hi! link TSPunctSpecial Special
" # Constants " # Constants
hi! link TSConstant Constant
hi! link TSConstBuiltin Constant
hi! link TSConstMacro Macro hi! link TSConstMacro Macro
hi! link TSStringRegex String
hi! link TSString String
hi! link TSStringEscape Character hi! link TSStringEscape Character
hi! link TSSymbol DraculaPurple hi! link TSSymbol DraculaPurple
hi! link TSCharacter Character
hi! link TSNumber Number
hi! link TSBoolean Boolean
hi! link TSFloat Float
hi! link TSAnnotation DraculaYellow hi! link TSAnnotation DraculaYellow
hi! link TSAttribute DraculaGreenItalic hi! link TSAttribute DraculaGreenItalic
hi! link TSNamespace Structure
" # Functions " # Functions
hi! link TSFuncBuiltin DraculaCyan hi! link TSFuncBuiltin DraculaCyan
hi! link TSFunction Function
hi! link TSFuncMacro Function hi! link TSFuncMacro Function
hi! link TSParameter DraculaOrangeItalic hi! link TSParameter DraculaOrangeItalic
hi! link TSParameterReference DraculaOrange hi! link TSParameterReference DraculaOrange
hi! link TSMethod Function
hi! link TSField DraculaOrange hi! link TSField DraculaOrange
hi! link TSProperty Normal
hi! link TSConstructor DraculaCyan hi! link TSConstructor DraculaCyan
" # Keywords " # Keywords
hi! link TSConditional Conditional
hi! link TSRepeat DraculaPink
hi! link TSLabel DraculaPurpleItalic hi! link TSLabel DraculaPurpleItalic
hi! link TSKeyword Keyword
hi! link TSKeywordFunction DraculaCyan
hi! link TSKeywordOperator Operator
hi! link TSOperator Operator
hi! link TSException DraculaPurple
hi! link TSType Type
hi! link TSTypeBuiltin Type
hi! link TSStructure Structure
hi! link TSInclude Include
" # Variable " # Variable
hi! link TSVariable Normal
hi! link TSVariableBuiltin DraculaPurpleItalic hi! link TSVariableBuiltin DraculaPurpleItalic
" # Text " # Text
hi! link TSText Normal
hi! link TSStrong DraculaFgBold hi! link TSStrong DraculaFgBold
hi! link TSEmphasis DraculaFg hi! link TSEmphasis DraculaFg
hi! link TSUnderline Underlined hi! link TSUnderline Underlined
hi! link TSTitle DraculaYellow hi! link TSTitle DraculaYellow
hi! link TSLiteral DraculaYellow hi! link TSLiteral DraculaYellow
hi! link TSURI DraculaYellow hi! link TSURI DraculaYellow
" # Tags
hi! link TSTag DraculaCyan
hi! link TSTagDelimiter Normal
endif endif
" }}} " }}}