If $nixFiles were expressed as relative to the root of the project, nixfmt would fail when ran from a sub directory. Now cd to the root first which will work for both relative and absolute paths.
Since nix (and thus we) have not committed to using flakes this instead uses git to find the root of the project.
If $nixFiles were expressed as relative to the root of the project, nixfmt would fail when ran from a sub directory. Now cd to the root first which will work for both relative and absolute paths.
Since nix (and thus we) have not committed to using flakes this instead uses git to find the root of the project.