Skip to content

Commit 2f0f924

Browse files
committed
Return early if version is linked or default
1 parent ded11c6 commit 2f0f924

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

.github/actions/prepare-test/action.yml

+8-4
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,14 @@ runs:
3232
run: |
3333
set -e # Fail this Action if `gh release list` fails.
3434
35+
if [[ ${{ inputs.version }} == "linked" ]]; then
36+
echo "tools-url=linked" >> "$GITHUB_OUTPUT"
37+
exit 0
38+
elif [[ ${{ inputs.version }} == "default" ]]; then
39+
echo "tools-url=" >> "$GITHUB_OUTPUT"
40+
exit 0
41+
fi
42+
3543
if [[ ${{ inputs.version }} == "nightly-latest" ]]; then
3644
extension="tar.zst"
3745
else
@@ -60,10 +68,6 @@ runs:
6068
elif [[ ${{ inputs.version }} == *"stable"* ]]; then
6169
version=`echo ${{ inputs.version }} | sed -e 's/^.*\-//'`
6270
echo "tools-url=https://github.com/github/codeql-action/releases/download/codeql-bundle-$version/$artifact_name" >> $GITHUB_OUTPUT
63-
elif [[ ${{ inputs.version }} == "linked" ]]; then
64-
echo "tools-url=linked" >> $GITHUB_OUTPUT
65-
elif [[ ${{ inputs.version }} == "default" ]]; then
66-
echo "tools-url=" >> $GITHUB_OUTPUT
6771
else
6872
echo "::error::Unrecognized version specified!"
6973
exit 1

0 commit comments

Comments
 (0)