#131 converting vim syntax highlighting to GeSHi ?

open-accepted
BenBE
5
2012-12-25
2012-01-06
Anonymous
No

hi there,
I am involved in the OSS FlightGear (GPL) flight simulator project (see flightgear.org), FlightGear supports a custom functional scripting language called "Nasal" (syntax is similar to php/perl) for extension purposes.

Nasal is heavily used all over FlightGear, including the wiki where it's documented. Right now, we are using the "php" highlighting mode from GeSHI.
But now, we'd like to create a proper GeSHI language definition for the Nasal language, we already have a vim syntax highlighting file that contains all important keywords and rules. So, there's no need for a completely new language definition. We would just like to convert it.

So we were wondering if anybody has come up with a script to convert vim syntax highlighting to GeSHI automatically?
Given the success of vim, and the plethora of custom programming languages, that would seem like a very useful tool to easily add support for new languages to GeSHi?

The vim file is available here: http://gitorious.org/fg/flightgear/blobs/next/scripts/syntax/nasal.vim
The vim syntax is documented here: http://vimdoc.sourceforge.net/htmldoc/syntax.html
Nasal is documented here: http://wiki.flightgear.org/Nasal_scripting_language
The official Nasal website is: http://plausible.org/nasal/
The Nasal standard library is documented here: http://plausible.org/nasal/lib.html

Thanks & all the best

- Hooray

Discussion

  • Nobody/Anonymous

    Just to add to this:

    If GeSHI could come up with a conversion script, or maybe an import mode/filter, to directly use vim files, GeSHi could automatically reuse hundreds of syntax highlighting definition files available already for vim.

    - Hooray

     
  • BenBE

    BenBE - 2012-08-16

    If you know a little php, it would not be hard to make it yourself. See section 4 of the documentation that comes with GeSHi.

    Otherwise, I'm not familiar with this language and so could not write the language file myself. If you could find someone with a little PHP experience and who knew your language, you could get them to write it.

     
  • BenBE

    BenBE - 2012-08-16
    • assigned_to: nobody --> benbe
    • milestone: --> Next_Release_(Stable)
    • status: open --> open-accepted
     
  • BenBE

    BenBE - 2012-08-16

    Unfortunately there's no automatic script for conversion of language files in VIM format yet, but given the documentation included with GeSHi isn't all that hard in order to create one GeSHi can use. Given Nasal seems simular to PHP you shouldn't have many problems.

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks