From eec0c618653cc909031e803a0cb7647210cc2791 Mon Sep 17 00:00:00 2001 From: ThomasAribart Date: Sat, 27 May 2023 11:49:09 +0200 Subject: [PATCH] build project with prev version of TS --- .github/actions/install-node-modules/action.yml | 8 +++++--- .github/workflows/pull-request.yml | 3 ++- .github/workflows/release.yml | 1 - 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/.github/actions/install-node-modules/action.yml b/.github/actions/install-node-modules/action.yml index dc82401..375116e 100644 --- a/.github/actions/install-node-modules/action.yml +++ b/.github/actions/install-node-modules/action.yml @@ -2,9 +2,11 @@ name: Install Node Dependencies description: Install dependencies using yarn inputs: node-version: + description: Node version to use required: true typescript-version: - required: true + description: TS version to use + default: "default" runs: using: composite steps: @@ -37,6 +39,6 @@ runs: run: if [ '${{ steps.sync-node-modules-cache.outputs.cache-hit }}' != 'true' ]; then yarn install --immutable; fi shell: bash - - name: Override TS with correct version - run: if [ '${{ steps.sync-node-modules-cache.outputs.cache-hit }}' != 'true' ]; then yarn add --dev typescript@${{ inputs.typescript-version }}; fi + - name: Override TS with specified version + run: if [ '${{ inputs.typescript-version }}' != 'default' ] && [ '${{ steps.sync-node-modules-cache.outputs.cache-hit }}' != 'true' ]; then yarn add --dev typescript@${{ inputs.typescript-version }}; fi shell: bash diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 87303e0..a0ed408 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -12,7 +12,8 @@ jobs: strategy: matrix: node: [16, 18] - typescript: ["~4.5.5", "~4.6.4", "~4.7.4", "~4.8.3", "~4.9.5", "~5.0.4"] + typescript: + ["default", "~4.6.4", "~4.7.4", "~4.8.3", "~4.9.5", "~5.0.4"] name: Node ${{ matrix.node }} / TS ${{ matrix.typescript }} steps: - uses: actions/checkout@v3 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0a51c74..4344459 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -40,7 +40,6 @@ jobs: uses: ./.github/actions/install-node-modules with: node-version: 18 - typescript-version: ~4.9.5 - name: Clear lib directory run: rm -rf lib