Fantomas vs stylish-haskell
Fantomas
fsprojects.github.iostylish-haskell
github.comSide by side
| Figure | Fantomas | stylish-haskell |
|---|---|---|
| Price from | Free | — |
| Free plan | Yes | — |
| Free trial | — | — |
| Open source | — | — |
| Web | Yes | — |
| Windows | Yes | Yes |
| macOS | Yes | — |
| Linux | Yes | Yes |
| Plans published | 1 | 0 |
| Spec score · Code Formatting Tools | 8.0 (#9) | 6.8 (#30) |
| Configuration | A limited set of formatting options can be stored in `.editorconfig` and read automatically by the command line tool. | Formatting is customizable through YAML configuration files, with settings available at directory, project, user, or default level. |
| Editor integrations | The maker provides setup guides for JetBrains Rider, Visual Studio Code, and Visual Studio. | The README documents integration with Haskell Language Server, Vim, Emacs, Atom, and Visual Studio Code. |
| Install | Fantomas is installed as a .NET tool, with local installation recommended so a repository can use a fixed version. | The project documents installation with Stack, Cabal, Debian or Ubuntu packages, and Arch Linux packages. |
| Purpose | Fantomas is an opinionated formatter for F# source code that formats files based on configuration. | stylish-haskell is a Haskell code prettifier designed to help with formatting tasks such as cleaning up import statements. |
Plans
In their own words
Fantomas
Fantomas formats F# source code according to configuration, using default rules based on Microsoft’s F# style guide. Settings are also available for G-Research conventions. It runs as a .NET tool, and local installation is recommended when a repository needs to keep a fixed version. The command line accepts folders or files with `.fs`, `.fsi`, `.fsx`, `.ml` or `.mli` extensions; source files are expected to parse with the F# compiler before formatting. A limited selection of options can be placed in `.editorconfig` for automatic use by the command-line tool. For continuous integration checks, `dotnet fantomas check` reports formatting drift and exits with a failure code when files need formatting. Setup guides are available for JetBrains Rider, Visual Studio Code and Visual Studio, and the official site links to an online tool for trying the formatter and its settings. Fantomas and its library are available under the Apache 2.0 license. The project is described as an fsprojects incubation project. It is free and open source, with web access listed alongside Linux, macOS and Windows.
stylish-haskell
stylish-haskell has no write-up on Specifiction yet; its figures are above.