stdenv: mute errors when failing to write env-vars

This commit is contained in:
tv 2021-01-05 21:42:18 +01:00
parent 5748022aa3
commit 659da9b738

View File

@ -787,7 +787,7 @@ substituteAllInPlace() {
# the environment used for building.
dumpVars() {
if [ "${noDumpEnvVars:-0}" != 1 ]; then
export >| "$NIX_BUILD_TOP/env-vars" || true
export 2>/dev/null >| "$NIX_BUILD_TOP/env-vars" || true
fi
}