lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Not sure where exactly this came from (credits in the source say
Written by Peter Odding, 2007/04/04), but it works.  It adds HTML tags
to Lua source code using a simple LPEG-based lexer:


the highlighting script:
http://www.mat.ucsb.edu/projects/luaAV/browser/trunk/buildtool/utilities/html.highlighter.lua

the lexer:
http://www.mat.ucsb.edu/projects/luaAV/browser/trunk/extra/modules/doc/lexer.lua

I posted that lexer to lua-l back in April 2007 [1], unfortunately I didn't attach the scripts but uploaded them to my former homepage, then promptly broke the links when my web server machine died some time later :-(. Lucky for me by then several people had saved a copy which means the scripts survived.

Recently I renewed my interest in syntax highlighting because I published the Lua/APR documentation [2] which includes example code that needs syntax highlighting, so I suppose I should salvage those scripts and give them a permanent home on GitHub :-)

 - Peter Odding

[1] http://lua-users.org/lists/lua-l/2007-04/msg00116.html
[2] http://peterodding.com/code/lua/apr/docs/