FREEDOM251

Freedom251 › Compare

Side by side

Ormolu vs shfmt

Both stand on code formatting tools. Which one you can start free with, which one lets you read the code, and what each costs once you pay.

Ormolu

Free plan LinuxMacWeb+1

Ormolu provides a single-style formatter for Haskell with command-line, browser, editor, and language-server paths. Its fixed style may not fit projects that need configurable formatting, and CPP handling is limited.

Visit Ormolu

shfmt

Free plan LinuxMacSelf-hosted+1

Choose shfmt for free shell formatting and syntax checking across its supported shell dialects, especially if you want directory processing or editor integration. Its key constraint is that formatting cannot be turned off for selected line ranges; the project also aims to keep its option set limited.

Visit shfmt

The facts

Ormolushfmt
Free planYesYes
Open sourceNot publishedNot published
Runs onLinux, Mac, Web, WindowsLinux, Mac, Self-hosted, Windows
Lowest paid planFree or on requestFree or on request
Plans published11
MakerNot publishedNot published
Websitegithub.comgithub.com
On code formatting tools#14 of 34#18 of 34

Ormolu: what it does well

  • Uses GHC's parser
  • Offers binaries for Linux, macOS, and Windows
  • Works with Emacs, VS Code, and Vim integrations
  • Haskell Language Server has built-in formatter support
  • Can read defaults from a matching Cabal file

What to know first

  • Formatting style cannot be configured
  • CPP support is experimental
  • CPP support is limited to simple top-level conditionals

shfmt: what it does well

  • Free and open source, with no paid plan stated.
  • Supports POSIX Shell, Bash, Zsh, mksh, and Bats.
  • Formats files, standard input, and directories recursively.
  • Can list, write, or diff files with formatting differences.
  • Reads options from EditorConfig when flags are absent.

What to know first

  • Cannot disable formatting for selected line ranges.
  • Requires valid UTF-8 for static syntax parsing.

Alternatives to Ormolu Alternatives to shfmt The whole list