diff options
author | laszlocsomor <laszlocsomor@google.com> | 2017-09-13 10:21:20 +0200 |
---|---|---|
committer | Philipp Wollermann <philwo@google.com> | 2017-09-13 19:06:31 +0200 |
commit | 84c1a55664d0f6461eabeb12176f8dca1271a23a (patch) | |
tree | 53ebeea5423ca47431ee4b9ccf9c0ab88890d844 /scripts | |
parent | e0bbe757b3626fbbadbab798e6752ca086e9ff46 (diff) |
bazel_bootstrap_distfile_test: add logging
Add logging to bazel_bootstrap_distfile_test.sh
and to buildenv.sh in hopes of catching this bug:
https://github.com/bazelbuild/bazel/issues/3618
For justification, see:
https://github.com/bazelbuild/bazel/issues/3618#issuecomment-328857891
RELNOTES: none
PiperOrigin-RevId: 168508723
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/bootstrap/buildenv.sh | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/bootstrap/buildenv.sh b/scripts/bootstrap/buildenv.sh index 88d7e4fc45..5c3682187c 100755 --- a/scripts/bootstrap/buildenv.sh +++ b/scripts/bootstrap/buildenv.sh @@ -166,7 +166,9 @@ function tempdir() { local DIR="$(mktemp -d "${tmp%%/}/bazel_XXXXXXXX")" mkdir -p "${DIR}" local DIRBASE=$(basename "${DIR}") - eval "cleanup_tempdir_${DIRBASE}() { rm -rf '${DIR}' >&/dev/null || true ; }" + # TODO(laszlocsomor): Remove the "[ -n ... ] && echo ... ;" part from the + # following command after we fixed https://github.com/bazelbuild/bazel/issues/3618. + eval "cleanup_tempdir_${DIRBASE}() { [ -n \"\$TEST_TMPDIR\" ] && echo \"DEBUG[$0 (\$(date))] deleting ($DIR)\" ; rm -rf '${DIR}' >&/dev/null || true ; }" atexit cleanup_tempdir_${DIRBASE} NEW_TMPDIR="${DIR}" } |