Replace the default formatter with nixfmt-tree
Is your feature request related to a problem? Please describe.
The current shell wrapper is a bit a bit crude.
Describe the solution you'd like
https://discourse.nixos.org/t/nix-formatting-team-full-nixpkgs-reformat/61867#p-206053-in-other-news-pkgsnixfmt-tree-4
Describe alternatives you've considered
Additional context
Very nice enhancement. But we do not (yet) have a policy regarding which NixOS branches we support, right?
nixfmt-tree seems to be in unstable only for the moment and not backported. Fine for me personally, as I don't use stable releases at all atm, but it might be good to either
- clarify that we support unstable only
- backport nixfmt-tree upstream
- wait for 25.05 to be released in ~2 months before adding it
Right. We should generally try to be back-compat with the last release. We're also missing tests to catch regressions on older releases.
For this specific issue, it's not urgent. We can wait 2 more months.