[Nix-dev] [***SPAM***] dead sources

Michael Raskin 7c6f434c at mail.ru
Sun Jan 6 18:10:17 CET 2013

>But instead of just having to wait for a while, the whole experience
>was a lot less pleasant, as the build process errored out every hour
>or so, because of missing source downloads. As I was not present the
>whole time, but only check/fix/restarted occasionally, I'm not even
>halfway done yet :(

I guess specifying -k (--keep-going) flag to nix-build would help.

nix-build /etc/nixos/nixos -k -A system

>I think it's important to be able to build nixos/nixpkgs fully from
>source, or at least know upfront if any download-related errors will
>I can think of 3 ways which could improve the current situation.
>a) --download-only option for nix-build
>That way, before attempting long builds, I can make sure I have all
>the sources, and don't even need an internet connection during the
>real build.

I am not sure how the flags get passed around inside... 

Right now you could use nix-reduce-build script inside nix repository...
Among its functionality is

nix-reduce-build /etc/nixos/nixos:-A:system -- nix-self-fixed://

It is not installed by default because it can do so many things that its
precise purpose is unclear.

It looks like NixOS system refers to some downloads that are not needed
even when building from near-scratch (and so some failures from 
nix-reduce-build are not significant), but it keeps trying the remaining
things on single failures so it downloads whatever it is possible.

More information about the nix-dev mailing list