Propagate NIX_BUILD_CORES to nix-shell environments

This commit is contained in:
Neil Mayhew 2017-04-08 18:31:11 -06:00
parent d8ff3aaae7
commit f12a048a05

View file

@ -406,6 +406,7 @@ int main(int argc, char ** argv)
env["NIX_BUILD_TOP"] = env["TMPDIR"] = env["TEMPDIR"] = env["TMP"] = env["TEMP"] = tmp;
env["NIX_STORE"] = store->storeDir;
env["NIX_BUILD_CORES"] = settings.buildCores;
for (auto & var : drv.env)
env[var.first] = var.second;