Skip to content

Commit 5c0ff26

Browse files
committed
8291444: GHA builds/tests won't run manually if disabled from automatic running
Reviewed-by: serb, erikj, ihse
1 parent 6d0fbb2 commit 5c0ff26

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

.github/workflows/main.yml

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -77,19 +77,17 @@ jobs:
7777
# 'false' otherwise.
7878
# arg $1: platform name or names to look for
7979
function check_platform() {
80-
if [[ '${{ !secrets.JDK_SUBMIT_FILTER || startsWith(github.ref, 'refs/heads/submit/') }}' == 'false' ]]; then
81-
# If JDK_SUBMIT_FILTER is set, and this is not a "submit/" branch, don't run anything
82-
echo 'false'
83-
return
84-
fi
85-
8680
if [[ $GITHUB_EVENT_NAME == workflow_dispatch ]]; then
8781
input='${{ github.event.inputs.platforms }}'
8882
elif [[ $GITHUB_EVENT_NAME == push ]]; then
89-
input='${{ secrets.JDK_SUBMIT_PLATFORMS }}'
90-
else
91-
echo 'Internal error in GHA'
92-
exit 1
83+
if [[ '${{ !secrets.JDK_SUBMIT_FILTER || startsWith(github.ref, 'refs/heads/submit/') }}' == 'false' ]]; then
84+
# If JDK_SUBMIT_FILTER is set, and this is not a "submit/" branch, don't run anything
85+
>&2 echo 'JDK_SUBMIT_FILTER is set and not a "submit/" branch'
86+
echo 'false'
87+
return
88+
else
89+
input='${{ secrets.JDK_SUBMIT_PLATFORMS }}'
90+
fi
9391
fi
9492
9593
normalized_input="$(echo ,$input, | tr -d ' ')"

0 commit comments

Comments
 (0)