Announcing nix-stylish-haskell-check - Enforce your Haskell source code passes stylish-haskell

I would like to announce nix-stylish-haskell-check:

nix-stylish-haskell-check is a small Nix library that produces a derivation that runs stylish-haskell over a set of input Haskell files.

If stylish-haskell detects that the input Haskell files aren’t formatted correctly, it fails the build of the derivation.

nix-stylish-haskell-check is convenient to use in CI to make sure all your Haskell files are formatted correctly.

It might also make sense to take a look at nix-stylish-haskell-check if you want to write a similar library for another Haskell formatter, like hindent, brittany, ormolu, etc.


At Cross Compass, we are using nix-stylish-haskell-check in our CI pipelines for all our important Haskell projects.

1 Like