on iko/ghcjs-patch-master help sign in
Fix callCabalProjectToNix when using nix sandboxes (#154)

* Fix callCabalProjectToNix when using nix sandboxes I am not sure why this works on hydra, but on default install of nix on ubuntu it fails to rename the plan-and-src $out because it is made read only by rsync. * Add comment regarding the nix sanbox issue

commitb82a06c37fa8d441932851e2d5ebc69c7f9954f6 authorHamish Mackenzie <Hamish.Mackenzie@iohk.io> dateWed 29 May 2019, 17:11 (7 years ago) parent53b3649
1 file changed+4
lib/cabalProjectToNix.nix+4
lib/cabalProjectToNix.nix+4
@@ -79,4 +79,8 @@ in
7979 # todo: should we clean `src` to drop any .git, .nix, ... other irelevant files?
8080 rsync -a "${src}/" "$out/"
8181 rsync -a ${plan}/ $out/
82+ # Rsync will have made $out read only and that can cause problems when
83+ # nix sandboxing is enabled (since it can prevent nix from moving the directory
84+ # out of the chroot sandbox).
85+ chmod +w $out
8286 ''