aboutsummaryrefslogtreecommitdiffstats
path: root/pkgs/populate/default.nix
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2026-11-12 02:33:44 +0000
committertv <tv@krebsco.de>2026-11-12 02:33:44 +0000
commit352dd5ce3107e2547db56802d773b919df03690f (patch)
tree1e5f6a3030e9eefee520728b1599f5ff6acf1f80 /pkgs/populate/default.nix
parentd63531d2d42524f5150d138000bec42fd49d1e71 (diff)
populate, krops writeDeploy: refer to generated flakes as path:
Generated flakes got locked with a bare nix flake lock in their directory, and writeDeploy deployed them by their path. Nix takes both for the enclosing Git work tree, if the target directory lies in one, e.g. a home directory kept in Git, and fails, because generated flakes aren't tracked there. Both refer to generated flakes as path: now. An edge case deploys into a Git work tree, and the deploy test covers deploying generated flakes.
Diffstat (limited to 'pkgs/populate/default.nix')
-rw-r--r--pkgs/populate/default.nix3
1 files changed, 2 insertions, 1 deletions
diff --git a/pkgs/populate/default.nix b/pkgs/populate/default.nix
index 08a624b..0992b0c 100644
--- a/pkgs/populate/default.nix
+++ b/pkgs/populate/default.nix
@@ -120,7 +120,8 @@ let
printf ' outputs = inputs: inputs.%s;\n' ${quote (toJSON name)}
echo '}'
} > flake.nix
- nix flake lock >&2
+ # Not just ., which Nix takes for the enclosing Git work tree, if any.
+ nix flake lock ${quote "path:${flakesDir}/${name}"} >&2
)
'';
in