From 1211a51d91c53b816ed7d33e1b0416b58a0d5703 Mon Sep 17 00:00:00 2001 From: Jakob Bornecrantz Date: Tue, 14 Jun 2022 16:26:17 +0100 Subject: [PATCH] ci: Use gradle clean on gradle builds --- .gitlab-ci.yml | 4 ++-- .gitlab-ci/ci.template | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a2833f249..2deef9f5d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -391,8 +391,8 @@ android:outOfProcess: - .gradlehome/caches script: - - rm -rf build - cp .gitlab-ci/local.properties . + - ./gradlew clean - ./gradlew assembleOutOfProcessDebug artifacts: paths: @@ -414,8 +414,8 @@ android:inProcess: - .gradlehome/caches script: - - rm -rf build - cp .gitlab-ci/local.properties . + - ./gradlew clean - ./gradlew assembleInProcessDebug artifacts: paths: diff --git a/.gitlab-ci/ci.template b/.gitlab-ci/ci.template index 4e618381f..30aa058c2 100644 --- a/.gitlab-ci/ci.template +++ b/.gitlab-ci/ci.template @@ -158,11 +158,11 @@ reuse: {% endif %} script: - - rm -rf build {#- regular or NDK cmake builds -#} {%- if "cmake" in job.name or "ndk" in job.name %} + - rm -rf build - cmake -GNinja -B build -S . {{- make_cmake_args(job.cmake_defines) }} - echo "Build Options:"; grep "^XRT_" build/CMakeCache.txt - ninja -C build @@ -171,6 +171,7 @@ reuse: {%- elif "android" in job.name %} - cp .gitlab-ci/local.properties . + - ./gradlew clean - ./gradlew {{ job.target }} {%- else %}