Skip to content

Commit

Permalink
Support nix 2.25 in formatter
Browse files Browse the repository at this point in the history
Nix 2.25 changes the args passed to the formatter, so we now need to
handle an empty args.

See NixOS/nix#11438
  • Loading branch information
accelbread committed Jan 15, 2025
1 parent bb0eb38 commit eedc71d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions builtinModules/formatter.nix
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ in
in
pkgs.writeShellScriptBin "formatter" ''
PATH=${if fullContext then "" else makeBinPath packages}
if [ $# -eq 0 ]; then exec "$0" .; fi
for f in "$@"; do
if [ -d "$f" ]; then
${fd}/bin/fd "$f" -Htf -x "$0" &
Expand Down

0 comments on commit eedc71d

Please sign in to comment.