Skip to content

Syntax highlighting, from running github-markup locally? #6716

Answered by lildude
deftclaw asked this question in Q&A
Discussion options

You must be logged in to vote

How can I utilize this tool to perform syntax highlighting with github/markup locally?

You can't 😁 Linguist doesn't do the syntax highlighting, it only collects the grammars which are passed to the syntax highlighting engine (that's the linguist-grammars.tar.gz file attached to each release).

This highlighting engine GitHub uses is not open source and is not available for use outside GitHub but if you want local syntax highlighting you'll need to look at something else like rouge which Jekyll uses (Ruby) or chroma which Hugo uses (Go). Both are static site generators that convert markdown to HTML, potentially saving you from reinventing the wheel.

There are others but that should get yo…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@deftclaw
Comment options

Answer selected by deftclaw
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants