1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-12 19:05:08 +02:00

Expose flake directory to nix fmt as PRJ_ROOT env var

This was discussed in https://github.com/NixOS/nix/issues/8034. I
personally like `PRJ_ROOT`, which hopefully avoids some ambiguity
around with subflakes.

I only implemented this for `nix fmt` because it doesn't let you point
at a flake not on your filesystem.

macOS compilation fixes
This commit is contained in:
Jeremy Fleischman 2025-05-07 11:24:50 -07:00 committed by Jörg Thalheim
parent 76a4d4c291
commit 17eb2e8400
6 changed files with 88 additions and 13 deletions

View file

@ -1,2 +1,2 @@
#!/usr/bin/env bash
echo "Formatting(${#}):" "${@}"
echo "PRJ_ROOT=$PRJ_ROOT Formatting(${#}):" "${@}"