Skip to content

Commit 3404bea

Browse files
committed
fix
1 parent 8b09a4d commit 3404bea

File tree

2 files changed

+18
-14
lines changed

2 files changed

+18
-14
lines changed

.github/workflows/cron_build.yml

+4-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,10 @@ jobs:
103103
name: Combine artifacts for IDF ${{ inputs.idf_branch }}
104104
runs-on: ubuntu-latest
105105
needs: [check-if-needed, build-libs]
106-
if: needs.check-if-needed.outputs.deploy_needed == '1'
106+
if: |
107+
always() &&
108+
needs.check-if-needed.result == 'success' &&
109+
needs.check-if-needed.outputs.deploy_needed == '1'
107110
steps:
108111
- uses: actions/checkout@v4
109112
with:

tools/check-deploy-needed.sh

+14-13
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,19 @@ export LIBS_HAS_RELEASE
6969
export LIBS_ASSET_ID
7070
export LIBS_HAS_ASSET
7171

72+
if [ "$LIBS_HAS_RELEASE" == "1" ]; then
73+
if [ "$LIBS_HAS_ASSET" == "0" ] || [ "$AR_HAS_COMMIT" == "0" ]; then
74+
echo "Deploy needed"
75+
export DEPLOY_NEEDED="1"
76+
else
77+
echo "Deploy not needed. Skipping..."
78+
export DEPLOY_NEEDED="0"
79+
fi
80+
else
81+
echo "Release for tag \"$LIBS_RELEASE_TAG\" not found. Please create the release first."
82+
exit 1
83+
fi
84+
7285
echo "IDF_COMMIT: $IDF_COMMIT"
7386
echo "AR_BRANCH: $AR_BRANCH"
7487
echo "AR_NEW_COMMIT_MESSAGE: $AR_NEW_COMMIT_MESSAGE"
@@ -83,19 +96,7 @@ echo "LIBS_RELEASE_ID: $LIBS_RELEASE_ID"
8396
echo "LIBS_HAS_RELEASE: $LIBS_HAS_RELEASE"
8497
echo "LIBS_ASSET_ID: $LIBS_ASSET_ID"
8598
echo "LIBS_HAS_ASSET: $LIBS_HAS_ASSET"
86-
87-
if [ "$LIBS_HAS_RELEASE" == "1" ]; then
88-
if [ "$LIBS_HAS_ASSET" == "0" ] || [ "$AR_HAS_COMMIT" == "0" ]; then
89-
echo "Deploy needed"
90-
export DEPLOY_NEEDED="1"
91-
else
92-
echo "Deploy not needed. Skipping..."
93-
export DEPLOY_NEEDED="0"
94-
fi
95-
else
96-
echo "Release for tag \"$LIBS_RELEASE_TAG\" not found. Please create the release first."
97-
exit 1
98-
fi
99+
echo "DEPLOY_NEEDED: $DEPLOY_NEEDED"
99100

100101
if [ ! -x $GITHUB_OUTPUT ]; then
101102
echo "idf_commit=$IDF_COMMIT" >> "$GITHUB_OUTPUT"

0 commit comments

Comments
 (0)