Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/workflows/cli-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,18 @@ jobs:
id: choose-ref
shell: bash
run: |
if [[ "${{ matrix.version }}" == "nightly" ]]
if [[ "$CLI_VERSION" == "nightly" ]]
then
REF="codeql-cli/latest"
else
REF="codeql-cli/${{ matrix.version }}"
# Validate the version read from supported_cli_versions.json before
# using it, to guard against script injection from untrusted input.
if [[ ! "$CLI_VERSION" =~ ^v?[0-9]+\.[0-9]+\.[0-9]+$ ]]
then
echo "Unexpected CLI version: '$CLI_VERSION'" >&2
exit 1
fi
REF="codeql-cli/$CLI_VERSION"
fi
echo "ref=$REF" >> "$GITHUB_OUTPUT"

Expand Down