Login  Register

Re: asciidoctor and pygments not working under cygwin64

Posted by wolandscat on Dec 30, 2019; 6:58pm
URL: https://discuss.asciidoctor.org/asciidoctor-and-pygments-not-working-under-cygwin64-tp5212p7462.html

I have had a look at the Rouge approach. It appears that this involves writing lexers as Ruby source files. I'm not personally against setting up a Ruby environment and learning enough Ruby to make that work, but it is not a very generic approach.

A better way would be to allow the use of something like Antlr4 files or some other independent lexer specification file that can be re-used across any particular implementation - e.g. how gvim does it, and how most parser builders work.

Ideally, one would be able to write a universally re-usable lexer file for any language that any syntax highlighting system, as well as other tools could use.

Aside: cygwin is much closer to a posix environment than Windows; everything runs inside bash, so testing on Windows native won't reveal anything about what might happen in cygwin. Generally speaking, if it works on Linux it works on cygwin. Which is why this anomaly is a surprise.