From f74c81a71b58eec00d5c042003721a5d4a41b367 Mon Sep 17 00:00:00 2001 From: Fu Hanxi Date: Wed, 22 Feb 2023 08:58:45 +0800 Subject: [PATCH] ci: add more ways to trigger upload cache --- .gitlab/ci/rules.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.gitlab/ci/rules.yml b/.gitlab/ci/rules.yml index f2fbf384f505..0892772f282b 100644 --- a/.gitlab/ci/rules.yml +++ b/.gitlab/ci/rules.yml @@ -331,6 +331,9 @@ .if-label-build-only: &if-label-build-only if: '$CI_JOB_STAGE == "target_test" && $CI_MERGE_REQUEST_LABELS =~ /^(?:[^,\n\r]+,)*For Maintainers: Only Build Tests(?:,[^,\n\r]+)*$/i' +.if-label-upload_cache: &if-label-upload_cache + if: '$CI_MERGE_REQUEST_LABELS =~ /^(?:[^,\n\r]+,)*upload_cache(?:,[^,\n\r]+)*$/i' + .if-revert-branch: &if-revert-branch if: '$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME =~ /^revert-/' @@ -356,11 +359,16 @@ .rules:patterns:python-cache: rules: + - *if-schedule + - <<: *if-label-upload_cache + when: manual - <<: *if-dev-push changes: *patterns-python-cache .rules:patterns:submodule: rules: + - <<: *if-label-upload_cache + when: manual - <<: *if-dev-push changes: *patterns-submodule