Skip to content

Commit

Permalink
use a preselected versions list by the default
Browse files Browse the repository at this point in the history
  • Loading branch information
pinzon committed Dec 16, 2024
1 parent c739659 commit 2cbbf50
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ on:
python-version:
required: false
default: '3.12'
run-all-latest-cdk-versions:
required: false
type: boolean
default: false

env:
AWS_ACCESS_KEY_ID: test
Expand All @@ -32,12 +36,21 @@ jobs:
uses: actions/setup-node@v2
with:
node-version: ${{ inputs.node-version }}
- name: Obtain aws-cdk versions
- name: Obtain all aws-cdk latest versions
id: set-matrix
if: ${{ inputs.run-all-latest-cdk-versions == true }}
run: |
VERSIONS_ARRAY=$(npm view aws-cdk versions --json | jq -c '.[-256:]' )
MATRIX="{\"cdk-version\":$VERSIONS_ARRAY}"
echo "MATRIX=$MATRIX" >> $GITHUB_OUTPUT
- name: Obtain default list of aws-cdk versions
id: set-matrix
if: ${{ inputs.run-all-latest-cdk-versions == false }}
run: |
VERSIONS_ARRAY=["1.10.0", "1.38.0", "1.95.1", "1.150.0", "2.30.0", "2.50.0", "2.75.0", "2.120.0", "2.166.0", "2.167.0", ""]
MATRIX="{\"cdk-version\":$VERSIONS_ARRAY}"
echo "MATRIX=$MATRIX" >> $GITHUB_OUTPUT

version-testing:
Expand Down

0 comments on commit 2cbbf50

Please sign in to comment.