From 0b0adc9d5bab8e36011ee120806e56f7d355810b Mon Sep 17 00:00:00 2001 From: Daniel Gröber Date: Mon, 17 Jun 2019 19:24:07 +0200 Subject: ci: Allow using latest Hackage index with CI_USE_COMMIT_INDEX_STATE=true --- scripts/ci/steps/10-update.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/ci/steps/10-update.sh b/scripts/ci/steps/10-update.sh index 7d0f042..d62e95d 100644 --- a/scripts/ci/steps/10-update.sh +++ b/scripts/ci/steps/10-update.sh @@ -1 +1,6 @@ -"$CI_SCRIPTS_DIR"/retry.sh cabal v2-update --index-state="@$(git show -s --format=%ct HEAD)" +update_args= +if ${CI_USE_COMMIT_INDEX_STATE:-true}; then + update_args=--index-state="@$(git show -s --format=%ct HEAD)" +fi + +"$CI_SCRIPTS_DIR"/retry.sh cabal v2-update $update_args -- cgit v1.2.3