@@ -292,7 +292,10 @@ jobs:
292
292
outputs :
293
293
versions : ${{ steps.compare.outputs.versions }}
294
294
nightly-url : ${{ steps.get-url.outputs.nightly-url }}
295
-
295
+ env :
296
+ # URL of the oldest release that we support, if this is being bumped then the constant
297
+ # CODEQL_MINIMUM_VERSION in the file codeql.ts should also be bumped to match this.
298
+ OLDEST_URL : https://github.com/github/codeql-action/releases/download/codeql-bundle-20201028/codeql-bundle.tar.gz
296
299
steps :
297
300
- uses : actions/checkout@v2
298
301
- name : Move codeql-action
@@ -336,31 +339,44 @@ jobs:
336
339
with :
337
340
tools : ${{ steps.get-url.outputs.nightly-url }}
338
341
languages : javascript
342
+ - name : Remove empty database
343
+ # allows us to run init a fourth time
344
+ run : |
345
+ rm -rf "$RUNNER_TEMP/codeql_databases"
346
+ - name : Init with a CodeQL bundle from the oldest supported release
347
+ id : init-oldest
348
+ uses : ./../action/init
349
+ with :
350
+ tools : ${{ env.OLDEST_URL }}
351
+ languages : javascript
339
352
- name : Compare CodeQL bundle versions
340
353
id : compare
341
354
env :
342
355
CODEQL_DEFAULT : ${{ steps.init-default.outputs.codeql-path }}
343
356
CODEQL_LATEST : ${{ steps.init-latest.outputs.codeql-path }}
344
357
CODEQL_NIGHTLY : ${{ steps.init-nightly.outputs.codeql-path }}
358
+ CODEQL_OLDEST : ${{ steps.init-oldest.outputs.codeql-path }}
345
359
NIGHTLY_URL : ${{ steps.get-url.outputs.nightly-url }}
346
360
run : |
347
361
CODEQL_VERSION_DEFAULT="$("$CODEQL_DEFAULT" version --format terse)"
348
362
CODEQL_VERSION_LATEST="$("$CODEQL_LATEST" version --format terse)"
349
363
CODEQL_VERSION_NIGHTLY="$("$CODEQL_NIGHTLY" version --format terse)"
364
+ CODEQL_VERSION_OLDEST="$("$CODEQL_OLDEST" version --format terse)"
350
365
echo "Default CodeQL bundle version is $CODEQL_VERSION_DEFAULT"
351
366
echo "Latest CodeQL bundle version is $CODEQL_VERSION_LATEST"
352
367
echo "Nightly CodeQL bundle version is $CODEQL_VERSION_NIGHTLY"
368
+ echo "Oldest supported CodeQL bundle version is $CODEQL_VERSION_OLDEST"
353
369
354
- # If we're running on a pull request, run each integration test with all three bundles, even
370
+ # If we're running on a pull request, run each integration test with all four bundles, even
355
371
# if `tools: latest` would be the same as `tools: null`. This allows us to make the
356
- # integration test job for each of the three bundles a required status check.
372
+ # integration test job for each of the four bundles a required status check.
357
373
#
358
374
# If we're running on push, then we can skip running with `tools: latest` when it would be
359
375
# the same as running with `tools: null`.
360
376
if [[ "$GITHUB_EVENT_NAME" != "pull_request" && "$CODEQL_VERSION_DEFAULT" == "$CODEQL_VERSION_LATEST" ]]; then
361
- VERSIONS_JSON="[null, \"$NIGHTLY_URL\"]"
377
+ VERSIONS_JSON="[null, \"$NIGHTLY_URL\", \"$OLDEST_URL\" ]"
362
378
else
363
- VERSIONS_JSON="[null, \"$NIGHTLY_URL\", \"latest\"]"
379
+ VERSIONS_JSON="[null, \"$NIGHTLY_URL\", \"$OLDEST_URL\", \" latest\"]"
364
380
fi
365
381
366
382
# Output a JSON-encoded list with the distinct versions to test against.
0 commit comments