From 3a0483e8ee0165c1e8592fc3fb474987c85489ca Mon Sep 17 00:00:00 2001 From: Joshua Yanovski Date: Thu, 23 Jan 2020 16:05:48 +0100 Subject: [PATCH] Fix asset caching issue in CI. --- .gitlab-ci.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7927f39e0f..6ab4816508 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,6 +16,8 @@ before_script: - free -h - cargo --version - export DISABLE_GIT_LFS_CHECK=true + - export VELOREN_ASSETS="$(pwd)/assets" + - echo "VELOREN_ASSETS=$VELOREN_ASSETS" - rm -r target || echo "target doesnt exist, which is fine" - ln -s /dockercache/veloren/target target @@ -32,7 +34,7 @@ before_script: optional-release:linux: <<: *optional-release script: - - VELOREN_ASSETS=assets cargo build --verbose --release + - cargo build --verbose --release - cp target/release/veloren-server-cli $CI_PROJECT_DIR - cp target/release/veloren-voxygen $CI_PROJECT_DIR - strip --strip-all veloren-server-cli @@ -48,7 +50,7 @@ optional-release:linux: optional-release:windows: <<: *optional-release script: - - VELOREN_ASSETS=assets cargo build --verbose --target=x86_64-pc-windows-gnu --release + - cargo build --verbose --target=x86_64-pc-windows-gnu --release - cp target/x86_64-pc-windows-gnu/release/veloren-server-cli.exe $CI_PROJECT_DIR - cp target/x86_64-pc-windows-gnu/release/veloren-voxygen.exe $CI_PROJECT_DIR artifacts: @@ -117,6 +119,7 @@ benchmarks: tags: - veloren-docker script: + - unset DISABLE_GIT_LFS_CHECK - cargo bench allow_failure: true @@ -132,7 +135,7 @@ linux: tags: - veloren-docker script: - - VELOREN_ASSETS=assets cargo build --release + - cargo build --release - cp -r target/release/veloren-server-cli $CI_PROJECT_DIR - cp -r target/release/veloren-voxygen $CI_PROJECT_DIR - strip --strip-all veloren-server-cli @@ -157,7 +160,7 @@ windows: tags: - veloren-docker script: - - VELOREN_ASSETS=assets cargo build --target=x86_64-pc-windows-gnu --release + - cargo build --target=x86_64-pc-windows-gnu --release - cp -r target/x86_64-pc-windows-gnu/release/veloren-server-cli.exe $CI_PROJECT_DIR - cp -r target/x86_64-pc-windows-gnu/release/veloren-voxygen.exe $CI_PROJECT_DIR artifacts: