- Parsing fixes
- Quotes in inherit statements (like
inherit "or";
) are now supported.
- Quotes in inherit statements (like
- Fix escaping of interpolations after dollar signs.
- Fix nixfmt trying to allocate temp files that aren't used.
- Don't write if files didn't change, fixing treefmt compatibility
- Nixfmt now accepts the '-' argument to read from stdin.
nixfmt [dir]
now recursively formats nix files in that directory.- Float and int literal parsing now matches nix.
- Add a nix flake to the nixfmt project.
- Add a --verify flag to check idempotency.
- Support nix path (
./${foo}.nix
) interpolations. - Fix escaping of interpolations after single quotes.
- Fix handling of multiline strings with spaces in the last line.
- Report non-conforming files on the same line to aid line-oriented processing
- Fix help, summary, and version flag contents.
- Fix indentation of leading comments in parens
- Added check flag for use in CI.
- Added quiet flag to disable all output on stderr.
- Further improved indentation.
- Fixed bugs where Nix code with different semantics was emitted in some cases.
- Fixed missing linebreaks in set abstractions.
- Fixed indentation of binders and some other expressions.
- Use atomic writes to avoid data loss.
- Made idempotent.
- Pinned nixpkgs.
- Simplified some code.
- Many other formatting improvements.
- The first released version of nixfmt. This project aims to provide a consistent formatter for Nix code. This release is capable of parsing all of nixpkgs and formatting it in a consistent way. The generated code is not yet pretty in all places though and there are still some other issues as well.