* Use df's -P option to ensure that the output is uniform regardless of the length of the device name.
* Use df's -P option to ensure that the output is uniform regardless of the length of the device name. svn path=/configurations/trunk/tud/; revision=32354
Eelco Dolstra committed
Feb 17, 2012 at 16:02 UTC
97e06d024bd5c0817605b6c4be69ad798c94eaa8
1 file changed
+1
-2
hydra-module.nix
+1
-2
@@ -112,8 +112,7 @@ in
112
nix.nrBuildUsers = 100;
113
114
nix.gc.automatic = true;
115
- # $3 / $4 don't always work depending on length of device name
116
- nix.gc.options = ''--max-freed "$((400 * 1024**3 - 1024 * $(df /nix/store | tail -n 1 | awk '{ print $3 }')))"'';
115
+ nix.gc.options = ''--max-freed "$((400 * 1024**3 - 1024 * $(df -P -k /nix/store | tail -n 1 | awk '{ print $4 }')))"'';
116
117
nix.extraOptions = ''
118
gc-keep-outputs = true