haskell-nix / hnix

A Haskell re-implementation of the Nix expression language
https://hackage.haskell.org/package/hnix
BSD 3-Clause "New" or "Revised" License
741 stars 114 forks source link

Fix pretty printer closing brace alignment #1090

Closed ners closed 8 months ago

ners commented 9 months ago

Before this PR, prettyNix generates docs like this:

{
  foo = {
    bar = [
      a
      b
      c
      ]
    }
  }

With this PR, the closing braces are more correctly aligned with the opening ones:

{
  foo = {
    bar = [
      a
      b
      c
    ]
  }
}
Anton-Latukha commented 8 months ago

Thank you.