1. Bitbucket Website
  2. Public Issue Tracker
  3. master


Issue #318 invalid

Syntax highlighting for F#

Tomas Linhart
created an issue


would be possilbe add syntax highlighting for language like F#?

I wanna start project here and I would welcome it.

More color profiles would be welcome also, because current are barely to see.


Comments (8)

  1. Eirik Stavem


    Seems there is currently no F# lexer available for pygments, the highlighter we use: http://dev.pocoo.org/projects/pygments/ticket/353

    As soon as one is available - or someone who knows F# well writes one ;) http://pygments.org/docs/lexerdevelopment/ - we'll add it.

    Do you mean the color profile for the code highlighter? If so, you can change that by going to the Admin-tab for your repository, and under Appearance Settings you can change both highlight style and tab width.

    Thanks for your report!

  2. Tomas Linhart reporter

    Thanks for reply.

    I checked Pygments and it's support OCaml which got almost same syntax as F#. OCaml lexer was found there http://dev.pocoo.org/projects/pygments/browser/pygments/lexers/functional.py , you can just add support for these extensions fs/.fsx/.fsi. Of course OCaml highlighter isn't best, but it's better than nothing. Some keywords aren't used by OCaml, but they can be easy added. There is F# highlighting for MonoDeveloper which covers all keywords. http://wildart.googlecode.com/svn/trunk/FSharpBinding/FSharpSyntaxMode.xml . I can try create F# lexer for Pygments unfortunately, I don't know how to test it if it works.

    Yes, I mean that. Thanks. I found it now.

  3. Log in to comment