Skip to content

Commit cfb3940

Browse files
henrymercerCopilot
andcommitted
Respect use-all-platform-bundle for the latest nightly in prepare-test
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
1 parent fbfa9f3 commit cfb3940

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

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

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,14 @@ runs:
3636
set -e # Fail this Action if `gh release list` fails.
3737
3838
if [[ "$VERSION" == "nightly" || "$VERSION" == "nightly-latest" ]]; then
39-
echo "tools-url=nightly" >> "$GITHUB_OUTPUT"
39+
if [[ "$USE_ALL_PLATFORM_BUNDLE" == "true" ]]; then
40+
# With `tools: nightly`, the Action downloads the bundle for the runner's platform, so look
41+
# up the latest nightly release here to get its all-platform bundle instead.
42+
tag=$(gh release list --repo dsp-testing/codeql-cli-nightlies --limit 1 --json tagName --jq '.[0].tagName')
43+
echo "tools-url=https://github.com/dsp-testing/codeql-cli-nightlies/releases/download/$tag/codeql-bundle.tar.gz" >> "$GITHUB_OUTPUT"
44+
else
45+
echo "tools-url=nightly" >> "$GITHUB_OUTPUT"
46+
fi
4047
exit 0
4148
elif [[ "$VERSION" == "linked" ]]; then
4249
echo "tools-url=linked" >> "$GITHUB_OUTPUT"

0 commit comments

Comments
 (0)