about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2006-09-25T10·29+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2006-09-25T10·29+0000
commit76c971009149f73453ccec66392625f2b67f8785 (patch)
tree7b0f5f3c73023076437acf54d95aeb5f9a01095c
parente347033f718e23d1ae6821207124465fedc73db1 (diff)
* Use builtins.toPath.
-rw-r--r--scripts/nix-push.in4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/nix-push.in b/scripts/nix-push.in
index 283d78a6117e..f11cd1f46f83 100644
--- a/scripts/nix-push.in
+++ b/scripts/nix-push.in
@@ -105,12 +105,12 @@ open NIX, ">$nixfile";
 print NIX "[";
 
 foreach my $storePath (@storePaths) {
-    die unless ($storePath =~ /\/[0-9a-z]{32}.*$/);
+    die unless ($storePath =~ /\/[0-9a-z]{32}[^\"\\\$]*$/);
 
     # Construct a Nix expression that creates a Nix archive.
     my $nixexpr = 
         "((import $dataDir/nix/corepkgs/nar/nar.nix) " .
-        "{storePath = $storePath; system = \"@system@\"; hashAlgo = \"$hashAlgo\";}) ";
+        "{storePath = builtins.toPath \"$storePath\"; system = \"@system@\"; hashAlgo = \"$hashAlgo\";}) ";
     
     print NIX $nixexpr;
 }