From 683ddf19dc855136eb4fe2e907910cf09a0c10ba Mon Sep 17 00:00:00 2001 From: Andres Gomez Date: Tue, 4 May 2021 22:10:54 +0300 Subject: [PATCH] ci: remove results directory content only with piglit runners Removing the directory itself can be problematic with certain runner strategies (B2C). v2: - Better deleting pattern matching since the previously used one was problematic and not pointed out by /bin/sh, as noticed by Emma. v3: - Check that the results directory exists before attempting to delete its content. Signed-off-by: Andres Gomez Reviewed-by: Martin Peres Part-of: --- .gitlab-ci/piglit/run.sh | 4 +++- .gitlab-ci/piglit/run_cl.sh | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci/piglit/run.sh b/.gitlab-ci/piglit/run.sh index d98c562c4b0..5c21ef5ccbd 100755 --- a/.gitlab-ci/piglit/run.sh +++ b/.gitlab-ci/piglit/run.sh @@ -176,7 +176,9 @@ replay_minio_upload_images() { SANITY_MESA_VERSION_CMD="$SANITY_MESA_VERSION_CMD | tee /tmp/version.txt | grep \"Mesa $MESA_VERSION\(\s\|$\)\"" -rm -rf results +if [ -d results ]; then + cd results && rm -rf ..?* .[!.]* * +fi cd /piglit if [ -n "$USE_CASELIST" ]; then diff --git a/.gitlab-ci/piglit/run_cl.sh b/.gitlab-ci/piglit/run_cl.sh index 506fb31867d..a1f01bb59e5 100755 --- a/.gitlab-ci/piglit/run_cl.sh +++ b/.gitlab-ci/piglit/run_cl.sh @@ -5,7 +5,9 @@ set -o xtrace VERSION=`cat install/VERSION` -rm -rf results +if [ -d results ]; then + cd results && rm -rf ..?* .[!.]* * +fi cd /piglit export OCL_ICD_VENDORS=$OLDPWD/install/etc/OpenCL/vendors/