This is an automated email from the ASF dual-hosted git repository.
miaoliyao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new 0a53ca33616 Refactor workflow trigger (#28731)
0a53ca33616 is described below
commit 0a53ca33616b09a4f98428129c44548b93e7d005
Author: 孙念君 Nianjun Sun <[email protected]>
AuthorDate: Thu Oct 12 12:45:19 2023 +0800
Refactor workflow trigger (#28731)
* Automated Change
* Automated Change
* Automated Change
* Refactor : remove useless file
* Refactor : refactor the switch for workflow
* Refactor : refactor the switch for workflow
* Refactor : refactor the switch variables
* Refactor : refactor the switch variables
* Refactor : refactor the switch variables
* Refactor : refactor the switch variables
* Fix : fix the shell syntax
* Refactor : remove useless command
---------
Co-authored-by: taojintianxia <[email protected]>
---
.github/workflows/required-reusable.yml | 6 +++++-
.github/workflows/resources/variables/env-variables.properties | 2 +-
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/.github/workflows/required-reusable.yml
b/.github/workflows/required-reusable.yml
index f55ec6c72f4..a933eb7de34 100644
--- a/.github/workflows/required-reusable.yml
+++ b/.github/workflows/required-reusable.yml
@@ -43,6 +43,7 @@ jobs:
echo ${line} >> $GITHUB_OUTPUT
done
echo "GLOBAL_REPOSITORY=${{ env.GLOBAL_REPOSITORY }}"
+ echo "DISABLE_CI=${{ env.DISABLE_CI }}"
GLOBAL_CACHE_PREFIX=$(echo '${{ env.GLOBAL_REPOSITORY }}' | sed
's/\//_/g')
echo "GLOBAL_CACHE_PREFIX=${GLOBAL_CACHE_PREFIX}" >> $GITHUB_OUTPUT
- name: Check If Job is Executable
@@ -55,7 +56,10 @@ jobs:
echo "GLOBAL_CACHE_PREFIX=${GLOBAL_CACHE_PREFIX}" >> $GITHUB_OUTPUT
if [ ${{ toJSON(github.repository) }} = ${{
steps.import-variables.outputs.GLOBAL_REPOSITORY }} ]; then
echo "GLOBAL_IS_NIGHTLY_JOB_EXECUTABLE=true" >> $GITHUB_OUTPUT
- echo "GLOBAL_JOB_ENABLED=true" >> $GITHUB_OUTPUT
+ echo "GLOBAL_JOB_ENABLED=false" >> $GITHUB_OUTPUT
+ if [ -z "${{ steps.import-variables.outputs.DISABLE_CI }}"] || [
"${{ steps.import-variables.outputs.DISABLE_CI }}"=="false" ] ; then
+ echo "GLOBAL_JOB_ENABLED=true" >> $GITHUB_OUTPUT
+ fi
fi
outputs:
GLOBAL_RUNS_ON: ${{ steps.import-variables.outputs.GLOBAL_RUNS_ON }}
diff --git a/.github/workflows/resources/variables/env-variables.properties
b/.github/workflows/resources/variables/env-variables.properties
index 6fa4ba00757..146a8c7920e 100644
--- a/.github/workflows/resources/variables/env-variables.properties
+++ b/.github/workflows/resources/variables/env-variables.properties
@@ -1,3 +1,3 @@
GLOBAL_REPOSITORY=apache/shardingsphere
GLOBAL_RUNS_ON=ubuntu-latest
-RUNNABLE_CI_LABEL=
+DISABLE_CI=false