jgm / skylighting

A Haskell syntax highlighting library with tokenizers derived from KDE syntax highlighting descriptions
190 stars 61 forks source link

Any future support for vimscript? #89

Closed MisanthropicBit closed 4 years ago

MisanthropicBit commented 4 years ago

I have a Hakyll blog which contains some vimscript/VimL (the scripting language of the vim editor) but the code is not highlighted since skylighting does not yet support it AFAIK. Neither is the language in this KDE syntax highlighting repository.

Are there any chances this will be supported at some point?

Vimscript is hard to highlight since many commands can be abbreviated. For example, the vimL lexer in pygments auto-generates a list of commands etc. that is then checked, which may or may not be possible in KDE. Alternatively, one could choose to only support non-abbreviated commands.

jgm commented 4 years ago

You might start by contributing a highlighting syntax definition for vimscript to KDE.

MisanthropicBit commented 4 years ago

True. I actually have one going on here (local commits pending) for skylighting itself but I cannot currently solve the abbreviation problem elegantly.

I'll continue to work on my fork, ignoring abbreviated commands, and submit a PR when it's ready.