about summary refs log tree commit diff
path: root/scripts
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2008-11-19T23·26+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2008-11-19T23·26+0000
commitaab530e9712baf802bcb48f03440a915dbc37ee9 (patch)
tree0a9d25b811dc91caabe2545c3e38c7ca0cc85bda /scripts
parent60564410ef34db8fd3c9be759bdc687366f24e8e (diff)
* Primop builtins.storePath for declaring a store path as a
  dependency.  `storePath /nix/store/bla' gives exactly the same
  result as `toPath /nix/store/bla', except that the former includes
  /nix/store/bla in the dependency context of the string.

  Useful in some generated Nix expressions like nix-push, which now
  finally does the right thing wrt distributed builds.  (Previously
  the path to be packed wasn't an explicit dependency, so it wouldn't
  be copied to the remote machine.)

Diffstat (limited to 'scripts')
-rw-r--r--scripts/nix-push.in2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/nix-push.in b/scripts/nix-push.in
index 1c910438fdb2..8ac31d50165e 100644
--- a/scripts/nix-push.in
+++ b/scripts/nix-push.in
@@ -107,7 +107,7 @@ foreach my $storePath (@storePaths) {
     # Construct a Nix expression that creates a Nix archive.
     my $nixexpr = 
         "((import $dataDir/nix/corepkgs/nar/nar.nix) " .
-        "{storePath = builtins.toPath \"$storePath\"; system = \"@system@\"; hashAlgo = \"$hashAlgo\";}) ";
+        "{storePath = builtins.storePath \"$storePath\"; system = \"@system@\"; hashAlgo = \"$hashAlgo\";}) ";
     
     print NIX $nixexpr;
 }