about summary refs log tree commit diff
path: root/scripts
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2012-07-27T13·57-0400
committerEelco Dolstra <eelco.dolstra@logicblox.com>2012-07-27T13·57-0400
commit7f8e805c8ef2d7728648553de6b762964730a09a (patch)
treeca6b3ba6a57f98b7a3f5828df4bb4990e2360e4d /scripts
parent67c6f3eded7dcb7c79243ed41f177c960f2b6aad (diff)
download-from-binary-cache: Only use the default cache for /nix/store
Diffstat (limited to 'scripts')
-rw-r--r--scripts/download-from-binary-cache.pl.in4
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/download-from-binary-cache.pl.in b/scripts/download-from-binary-cache.pl.in
index 10d0db9adb..9369224005 100644
--- a/scripts/download-from-binary-cache.pl.in
+++ b/scripts/download-from-binary-cache.pl.in
@@ -13,7 +13,9 @@ use strict;
 Nix::Config::readConfig;
 
 my @binaryCacheUrls = map { s/\/+$//; $_ } split(/ /,
-    ($ENV{"NIX_BINARY_CACHES"} // $Nix::Config::config{"binary-caches"} // "http://nixos.org/binary-cache"));
+    ($ENV{"NIX_BINARY_CACHES"}
+     // $Nix::Config::config{"binary-caches"}
+     // ($Nix::Config::storeDir eq "/nix/store" ? "http://nixos.org/binary-cache" : "")));
 
 my $maxParallelRequests = int($Nix::Config::config{"binary-caches-parallel-connections"} // 150);
 $maxParallelRequests = 1 if $maxParallelRequests < 1;