stylish-haskell icon indicating copy to clipboard operation
stylish-haskell copied to clipboard

Doesn't support literate haskell

Open spacekitteh opened this issue 10 years ago • 4 comments

Specifically, it doesn't appear to support literate haskell in latex mode.

spacekitteh avatar Mar 05 '14 08:03 spacekitteh

Is there any plan to support this?

iphydf avatar Mar 03 '16 22:03 iphydf

For anyone who wants to use literate haskell (in latex mode) with stylish-haskell, I wrote this script. It works for my use case and isn't forgiving if your format isn't exactly right.

Usage: format-haskell <directory>

The tool extracts the code between \begin{code} and \end{code} (anchored to beginning and end of line, so no space before and after!), runs stylish-haskell on it, and then splices it back into the code sections, replacing the old code.

Use at your own risk, no guarantees that it does what you want. Always use backups/editor undo.

iphydf avatar Mar 04 '16 11:03 iphydf

There are currently no plans to add this to stylish-haskell. It's not impossible, but it would require a decent amount of work.

jaspervdj avatar Mar 28 '16 10:03 jaspervdj

Just to be clear, stylish-haskell doesn't support the bird-track-style LHS either, right? These comments almost seem to indicate that they do, but not LaTeX-style. But as the title indicates, I don't think stylish-haskell supports LHS in either style.

shajra avatar Jul 16 '18 03:07 shajra