diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 70061d97..5519ee53 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -14,13 +14,14 @@ on: jobs: build: + name: Build and Test (${{ matrix.os }}, node-${{ matrix.node-version }}) runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest] - node: [18] + node-version: [18, 20, 22] steps: - name: Checkout @@ -28,10 +29,10 @@ jobs: with: persist-credentials: false - - name: Use Node.js ${{ matrix.node }} + - name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v4 with: - node-version: ${{ matrix.node }} + node-version: ${{ matrix.node-version }} registry-url: 'https://registry.npmjs.org' - name: Build @@ -50,14 +51,16 @@ jobs: NODE_OPTIONS: "--max_old_space_size=4096" publish-next: + name: Publish to npm (next) needs: build if: github.ref == 'refs/heads/master' && github.event_name == 'push' && github.repository == 'eclipse-cdt-cloud/timeline-chart' - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} strategy: matrix: - node: [18] + os: [ubuntu-latest] + node-version: [20] steps: - name: Checkout @@ -65,10 +68,10 @@ jobs: with: persist-credentials: false - - name: Use Node.js ${{ matrix.node }} + - name: Use Node.js ${{ matrix.node-version}} uses: actions/setup-node@v4 with: - node-version: ${{ matrix.node }} + node-version: ${{ matrix.node-version }} registry-url: 'https://registry.npmjs.org' - name: Pre-Publish @@ -91,21 +94,23 @@ jobs: NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} # The variable name comes from here: https://github.com/actions/setup-node/blob/70b9252472eee7495c93bb1588261539c3c2b98d/src/authutil.ts#L48 publish-latest: + name: Publish to npm (latest) needs: build if: github.event_name == 'release' && startsWith(github.ref, 'refs/tags/v') && github.repository == 'eclipse-cdt-cloud/timeline-chart' - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} strategy: matrix: - node: [18] + os: [ubuntu-latest] + node-version: [20] steps: - name: Checkout uses: actions/checkout@v3 with: persist-credentials: false - - name: Use Node.js ${{ matrix.node }} + - name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v3 with: - node-version: ${{ matrix.node }} + node-version: ${{ matrix.node-version }} registry-url: 'https://registry.npmjs.org' - name: Pre-Publish shell: bash diff --git a/.github/workflows/license-check-workflow.yml b/.github/workflows/license-check-workflow.yml index b79f9f60..922ac6bb 100644 --- a/.github/workflows/license-check-workflow.yml +++ b/.github/workflows/license-check-workflow.yml @@ -14,13 +14,13 @@ on: jobs: License-check: - name: 3PP License Check using dash-licenses + name: 3PP License Check using dash-licenses (${{ matrix.os }}) strategy: fail-fast: false matrix: os: [ubuntu-latest] - node: [18] + node-version: [20] java: [11] runs-on: ${{ matrix.os }} @@ -35,7 +35,7 @@ jobs: - name: Use Node.js ${{ matrix.node }} uses: actions/setup-node@v4 with: - node-version: ${{ matrix.node }} + node-version: ${{ matrix.node-version }} - name: Use Java ${{ matrix.java }} uses: actions/setup-java@v3