[Snowball-discuss] Snowball Plugin for Pygments Syntax Highlighter

Olly Betts olly at survex.com
Fri Oct 9 21:50:26 BST 2015


On Mon, Apr 15, 2013 at 03:16:17AM +0900, Hajime Senuma wrote:
> I wrote a Snowball lexer plugin for Pygments, a popular syntax highlighter
> written with Python:
> https://github.com/hajimes/pygments-snowball.

Nice - I've added a link to: http://snowballstem.org/projects.html

> For ease of implementation, the lexer has a defect that it assumes
> stringescapes are curly brackets, but it'll work for most Snowball codes.

While ideally it'd support the full syntax, in practice everyone seems
to follow Martin's lead and use curly brackets, so this doesn't seem
too much of a limitation.

> I would be glad if you could use this to make codes in your html documents
> more readable.

Yes, that'd be good - it should help people follow the code.

Currently they're static HTML conversions, but we should really be
generating them from the code in the snowball repo (I bet some don't
match the current code in the repository) and it would be easy to do
syntax highlighting during that conversion.

Cheers,
    Olly



More information about the Snowball-discuss mailing list