Repository navigation
Update dependencies and relax CI Node version pin #290
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI/CD Build Tests | |
| on: | |
| push: | |
| pull_request: | |
| release: | |
| types: [published] | |
| schedule: | |
| - cron: '30 3 * * 1,6' | |
| jobs: | |
| build: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, windows-latest, macos-latest] | |
| node: ['22', '24'] | |
| name: ${{ matrix.os }} - Node ${{ matrix.node }} Test | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| name: Set up Node (NPM Cache) | |
| with: | |
| node-version: ${{ matrix.node }} | |
| cache: npm | |
| cache-dependency-path: package-lock.json | |
| if: hashFiles('package-lock.json') != '' | |
| - uses: actions/setup-node@v4 | |
| name: Set up Node (Yarn Cache) | |
| with: | |
| node-version: ${{ matrix.node }} | |
| cache: yarn | |
| cache-dependency-path: yarn.lock | |
| if: hashFiles('yarn.lock') != '' | |
| - name: Install Yarn | |
| run: npm install -g yarn | |
| - name: Install Dependencies | |
| run: yarn | |
| - name: Execute Unit Tests | |
| run: yarn test | |
| publish: | |
| needs: build | |
| if: github.event_name == 'release' | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| id-token: write | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| - name: Update npm for OIDC support | |
| run: npm install -g npm@latest | |
| - name: Install Yarn | |
| run: npm install -g yarn | |
| - name: Install Dependencies | |
| run: yarn | |
| - name: Publish to NPM | |
| run: npm publish --access public --provenance |