Jun 01
Eric Knibbe Pygments: now with more Lasso
Jun 01, 2012; 13:38
Eric Knibbe
Pygments: now with more Lasso
For anyone interested, I've posted my fork of the Pygments project with support added for highlighting Lasso 8 or 9 code. It's capable of:
- hilighting any surrounding HTML, XML, CSS, or JavaScript using the appropriate lexer
- handling Lasso 9 shell scripts
- ignoring code inside [noprocess] blocks
- recognizing type, trait, query expression, member data, member method, and unbound method definitions
- tagging escape sequences within single- or double-quoted strings
- handling built-in tags, types, traits, and methods for both Lasso 8 and 9
If you want to try it out, read the first three pages at <http://pygments.org/docs/>, then follow instructions for "installing the development version", except clone my Mercurial repository at <https://bitbucket.org/EricFromCanada/pygments-main>. Once that's done, you should be able to run `pygmentize -l lasso sourcefile.lasso` to preview its output in Terminal.*
If you'd like to contribute, there's a few things that need work:
- it's not very good at detecting Lasso code in files that lack the .lasso extension. (This only applies when asking Pygments to guess which lexer to use, rather than specifying it manually.) Anyone with strong Python-fu is encouraged to tackle this.
- it's only been tested on the handful of Lasso source files I had on hand, so any examples of valid code that trips up the lexer would be appreciated. It should also be able to handle shoddy or incorrect code, but again, more testing is in order.
- it'll have a better chance of being incorporated into the main trunk if it includes a file or two of example code that demonstrates Lasso syntax with as much variety as possible.
Success? Failure? Suggestions? Let me know.
‐‐‐‐‐‐‐‐‐‐✂‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐
Eric3
* I'm told that for Mac devs to use Apple's or MacPorts' Python is a Bad Idea, so... http://jessenoller.com/2009/03/16/so-you-want-to-use-python-on-the-mac/
#############################################################
This message is sent to you because you are subscribed to
the mailing list Lasso
Lasso@lists.lassosoft.com
To unsubscribe, E-mail to: <Lasso-unsubscribe@lists.lassosoft.com>
Send administrative queries to <Lasso-request@lists.lassosoft.com>
Jun 01
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Jun 01, 2012; 11:37
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Jun 01
Eric Landmann Re: Pygments: now with more Lasso
Jun 01, 2012; 15:36
Eric Landmann
Re: Pygments: now with more Lasso
Jun 01
Eric Knibbe Re: Pygments: now with more Lasso
Jun 01, 2012; 16:51
Eric Knibbe
Re: Pygments: now with more Lasso
Jun 01
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Jun 01, 2012; 14:00
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Jun 01
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Jun 01, 2012; 15:53
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Jun 01
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Jun 01, 2012; 16:25
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Jun 01
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Jun 01, 2012; 17:16
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Jun 01
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Jun 01, 2012; 18:40
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Aug 17
Eric Knibbe Re: Pygments: now with more Lasso
Aug 17, 2012; 23:22
Eric Knibbe
Re: Pygments: now with more Lasso
Aug 17
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Aug 17, 2012; 20:56
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Aug 19
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Aug 19, 2012; 02:27
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso
Aug 19
Steve Piercy - Web Site Builder Re: Pygments: now with more Lasso
Aug 19, 2012; 07:36
Steve Piercy - Web Site Builder
Re: Pygments: now with more Lasso