From 763b5572620390e24439c117ffd048bb9b1f1d8d Mon Sep 17 00:00:00 2001 From: Andres Gomez Date: Wed, 5 May 2021 10:10:44 +0300 Subject: [PATCH] ci: make sure we only read the first line from install/VERSION Signed-off-by: Andres Gomez Reviewed-by: Martin Peres Part-of: --- .gitlab-ci/piglit/run.sh | 2 +- .gitlab-ci/piglit/run_cl.sh | 2 +- .gitlab-ci/prepare-artifacts.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci/piglit/run.sh b/.gitlab-ci/piglit/run.sh index 5c21ef5ccbd..9fa607df648 100755 --- a/.gitlab-ci/piglit/run.sh +++ b/.gitlab-ci/piglit/run.sh @@ -15,7 +15,7 @@ export __LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$INSTALL/lib/" # Sanity check to ensure that our environment is sufficient to make our tests # run against the Mesa built by CI, rather than any installed distro version. -MESA_VERSION=$(cat "$INSTALL/VERSION" | sed 's/\./\\./g') +MESA_VERSION=$(head -1 "$INSTALL/VERSION" | sed 's/\./\\./g') print_red() { RED='\033[0;31m' diff --git a/.gitlab-ci/piglit/run_cl.sh b/.gitlab-ci/piglit/run_cl.sh index a1f01bb59e5..b32e1e63607 100755 --- a/.gitlab-ci/piglit/run_cl.sh +++ b/.gitlab-ci/piglit/run_cl.sh @@ -3,7 +3,7 @@ set -e set -o xtrace -VERSION=`cat install/VERSION` +VERSION=`head -1 install/VERSION` if [ -d results ]; then cd results && rm -rf ..?* .[!.]* * diff --git a/.gitlab-ci/prepare-artifacts.sh b/.gitlab-ci/prepare-artifacts.sh index 1067f24465b..26a58bfd97e 100755 --- a/.gitlab-ci/prepare-artifacts.sh +++ b/.gitlab-ci/prepare-artifacts.sh @@ -24,7 +24,7 @@ fi # Test runs don't pull down the git tree, so put the dEQP helper # script and associated bits there. -echo "$(cat VERSION) (git-$(git rev-parse HEAD | cut -b -10))" >> install/VERSION +echo "$(cat VERSION) (git-$(git rev-parse HEAD | cut -b -10))" > install/VERSION cp -Rp .gitlab-ci/bare-metal install/ cp -Rp .gitlab-ci/common install/ cp -Rp .gitlab-ci/piglit install/