From 9b8684bf14933f682f9aaaa59a86c5dc4ed5f48e Mon Sep 17 00:00:00 2001 From: "octoherd-stoe[bot]" <121860383+octoherd-stoe[bot]@users.noreply.github.com> Date: Fri, 7 Aug 2026 06:55:19 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=A4=96=20actions:=20Update=20Node.js=20ve?= =?UTF-8?q?rsion=20to=2024?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/policy-lerna-publish.yml | 42 ++++---------- .github/workflows/policy-lerna-test.yml | 54 +++++++----------- .github/workflows/policy-node-publish.yml | 42 ++++---------- .github/workflows/policy-node-test.yml | 57 +++++++------------ .../workflows/policy-workspaces-publish.yml | 42 ++++---------- 5 files changed, 73 insertions(+), 164 deletions(-) diff --git a/.github/workflows/policy-lerna-publish.yml b/.github/workflows/policy-lerna-publish.yml index 831a9cb..73dfb10 100644 --- a/.github/workflows/policy-lerna-publish.yml +++ b/.github/workflows/policy-lerna-publish.yml @@ -1,95 +1,75 @@ name: reusable publish (lerna) - on: workflow_call: inputs: npm: - description: 'Publish lerna monorepo to NPM' + description: Publish lerna monorepo to NPM type: boolean default: false gh: - description: 'Publish lerna monorepo to GitHub Packages' + description: Publish lerna monorepo to GitHub Packages type: boolean default: true secrets: npm_token: required: false - env: NODE_VERSION: 22 - NPM_SCOPE: '@stoe' - + NPM_SCOPE: "@stoe" jobs: publish_npm: if: ${{ inputs.npm }} - runs-on: ubuntu-latest - concurrency: group: ${{ github.workflow }}-npm-${{ github.ref }} cancel-in-progress: true - permissions: contents: read packages: write - env: CI: true NODE_AUTH_TOKEN: ${{ secrets.npm_token }} - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 - name: Setup Node.js - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ env.NODE_VERSION }} + node-version: 24 scope: ${{ env.NPM_SCOPE }} - registry-url: 'https://registry.npmjs.org' - + registry-url: https://registry.npmjs.org - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile git ls-files -z . | xargs -0 git update-index --assume-unchanged - - name: GitHub Packages publish run: npx lerna publish from-package --yes --registry https://registry.npmjs.org - publish_gh: if: ${{ inputs.gh }} - runs-on: ubuntu-latest - concurrency: group: ${{ github.workflow }}-gh-${{ github.ref }} cancel-in-progress: true - permissions: contents: read packages: write - env: CI: true NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 - name: Setup Node.js - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ env.NODE_VERSION }} + node-version: 24 scope: ${{ env.NPM_SCOPE }} - registry-url: 'https://npm.pkg.github.com' - + registry-url: https://npm.pkg.github.com - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile git ls-files -z . | xargs -0 git update-index --assume-unchanged - - name: GitHub Packages publish run: npx lerna publish from-package --yes --registry https://npm.pkg.github.com diff --git a/.github/workflows/policy-lerna-test.yml b/.github/workflows/policy-lerna-test.yml index e435a70..3b2e800 100644 --- a/.github/workflows/policy-lerna-test.yml +++ b/.github/workflows/policy-lerna-test.yml @@ -1,103 +1,87 @@ name: reusable test (lerna) - on: - workflow_call: - + workflow_call: null jobs: test-matrix: runs-on: ubuntu-latest - permissions: contents: read packages: read - env: CI: true NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - strategy: fail-fast: true matrix: node-version: - - 20 - - 22 - experimental: [false] + - 24 + - 24 + experimental: + - false include: - node-version: 24 experimental: true - node-version: lts/* experimental: true - continue-on-error: ${{ matrix.experimental }} - concurrency: group: ${{ github.workflow }}-${{ github.ref }}-${{ matrix.node-version }} cancel-in-progress: true - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 with: lfs: true - - name: Check repository visibility if: ${{ github.event_name == 'pull_request' }} id: visibility - run: | - echo "isPrivate=$(gh repo view --json isPrivate --jq '.isPrivate')" >> $GITHUB_OUTPUT + run: > + echo "isPrivate=$(gh repo view --json isPrivate --jq '.isPrivate')" >> + $GITHUB_OUTPUT env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - name: Check repository dependency graph - uses: actions/dependency-review-action@a1d282b36b6f3519aa1f3fc636f609c47dddb294 # v5.0.0 - if: ${{ github.event_name == 'pull_request' && steps.visibility.outputs.isPrivate == 'false' }} - + uses: actions/dependency-review-action@a1d282b36b6f3519aa1f3fc636f609c47dddb294 + if: ${{ github.event_name == 'pull_request' && + steps.visibility.outputs.isPrivate == 'false' }} - name: Setup Node.js v${{ matrix.node-version }} - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ matrix.node-version }} - registry-url: 'https://npm.pkg.github.com' - cache: 'npm' - + node-version: 24 + registry-url: https://npm.pkg.github.com + cache: npm - name: Get NPM cache directory id: npm-cache-dir run: | echo "NPM_CACHE_DIR=$(npm config get cache)" >> "$GITHUB_OUTPUT" - - name: Cache node modules id: cache-npm - uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0 + uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 env: cache-name: cache-node-modules with: path: ${{ steps.npm-cache-dir.outputs.NPM_CACHE_DIR }} - key: npm-${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} + key: npm-${{ runner.os }}-${{ env.cache-name }}-${{ + hashFiles('**/package-lock.json') }} restore-keys: | npm-${{ runner.os }}-${{ env.cache-name }}- npm-${{ runner.os }}- npm- - - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile - - name: List the state of node modules if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} continue-on-error: true run: npm list --omit=dev - - name: Build run: npm run build --if-present - - name: Test run: npx lerna run test - test: runs-on: ubuntu-latest - needs: test-matrix - steps: - name: Success run: echo "success" diff --git a/.github/workflows/policy-node-publish.yml b/.github/workflows/policy-node-publish.yml index 7b76843..93a7b3f 100644 --- a/.github/workflows/policy-node-publish.yml +++ b/.github/workflows/policy-node-publish.yml @@ -1,92 +1,72 @@ name: reusable publish (package) - on: workflow_call: inputs: npm: - description: 'Publish to NPM' + description: Publish to NPM type: boolean default: false gh: - description: 'Publish to GitHub Packages' + description: Publish to GitHub Packages type: boolean default: true - env: NODE_VERSION: 24 - NPM_SCOPE: '@stoe' - + NPM_SCOPE: "@stoe" jobs: publish_npm: if: ${{ inputs.npm }} - runs-on: ubuntu-latest - concurrency: group: ${{ github.workflow }}-npm-${{ github.ref }} cancel-in-progress: true - permissions: contents: read id-token: write - env: CI: true - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 - name: Setup Node.js - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ env.NODE_VERSION }} + node-version: 24 scope: ${{ env.NPM_SCOPE }} - registry-url: 'https://registry.npmjs.org' - + registry-url: https://registry.npmjs.org - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile git ls-files -z . | xargs -0 git update-index --assume-unchanged - - name: NPM publish run: NODE_AUTH_TOKEN="" npm publish --access public --provenance - publish_gh: if: ${{ inputs.gh }} - runs-on: ubuntu-latest - concurrency: group: ${{ github.workflow }}-gh-${{ github.ref }} cancel-in-progress: true - permissions: contents: read packages: write id-token: write - env: CI: true NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 - name: Setup Node.js - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ env.NODE_VERSION }} + node-version: 24 scope: ${{ env.NPM_SCOPE }} - registry-url: 'https://npm.pkg.github.com' - + registry-url: https://npm.pkg.github.com - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile git ls-files -z . | xargs -0 git update-index --assume-unchanged - - name: GitHub Packages publish run: npm publish --access public diff --git a/.github/workflows/policy-node-test.yml b/.github/workflows/policy-node-test.yml index 0d960e2..77bbcf3 100644 --- a/.github/workflows/policy-node-test.yml +++ b/.github/workflows/policy-node-test.yml @@ -1,102 +1,87 @@ name: reusable test - on: - workflow_call: - + workflow_call: null jobs: test-matrix: runs-on: ubuntu-latest - permissions: contents: read packages: read - env: CI: true NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - strategy: fail-fast: true matrix: node-version: - - 22 - 24 - optional: [false] + - 24 + optional: + - false include: - node-version: 25 optional: true - node-version: lts/* optional: true - continue-on-error: ${{ matrix.optional }} - concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ matrix.node-version }}-${{ matrix.optional }} + group: ${{ github.workflow }}-${{ github.ref }}-${{ matrix.node-version }}-${{ + matrix.optional }} cancel-in-progress: true - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 - name: Check repository visibility if: ${{ github.event_name == 'pull_request' }} id: visibility - run: | - echo "isPrivate=$(gh repo view --json isPrivate --jq '.isPrivate')" >> $GITHUB_OUTPUT + run: > + echo "isPrivate=$(gh repo view --json isPrivate --jq '.isPrivate')" >> + $GITHUB_OUTPUT env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - name: Check repository dependency graph - uses: actions/dependency-review-action@a1d282b36b6f3519aa1f3fc636f609c47dddb294 # v5.0.0 - if: ${{ github.event_name == 'pull_request' && steps.visibility.outputs.isPrivate == 'false' }} - + uses: actions/dependency-review-action@a1d282b36b6f3519aa1f3fc636f609c47dddb294 + if: ${{ github.event_name == 'pull_request' && + steps.visibility.outputs.isPrivate == 'false' }} - name: Setup Node.js v${{ matrix.node-version }} - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ matrix.node-version }} - registry-url: 'https://npm.pkg.github.com' - scope: '@stoe' - cache: 'npm' - + node-version: 24 + registry-url: https://npm.pkg.github.com + scope: "@stoe" + cache: npm - name: Get NPM cache directory id: npm-cache-dir run: | echo "NPM_CACHE_DIR=$(npm config get cache)" >> "$GITHUB_OUTPUT" - - name: Cache node modules id: cache-npm - uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0 + uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 env: cache-name: cache-node-modules with: path: ${{ steps.npm-cache-dir.outputs.NPM_CACHE_DIR }} - key: npm-${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} + key: npm-${{ runner.os }}-${{ env.cache-name }}-${{ + hashFiles('**/package-lock.json') }} restore-keys: | npm-${{ runner.os }}-${{ env.cache-name }}- npm-${{ runner.os }}- npm- - - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile - - name: List the state of node modules if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} continue-on-error: true run: npm list --omit=dev - - name: Build run: npm run build --if-present - - name: Test run: npm run test --if-present - test: runs-on: ubuntu-latest - needs: test-matrix - steps: - name: Success run: echo "success" diff --git a/.github/workflows/policy-workspaces-publish.yml b/.github/workflows/policy-workspaces-publish.yml index 5a5f75f..928efa8 100644 --- a/.github/workflows/policy-workspaces-publish.yml +++ b/.github/workflows/policy-workspaces-publish.yml @@ -1,98 +1,78 @@ name: reusable publish (workspace package) - on: workflow_call: inputs: npm: - description: 'Publish workspaces to NPM' + description: Publish workspaces to NPM type: boolean default: false gh: - description: 'Publish workspaces to GitHub Packages' + description: Publish workspaces to GitHub Packages type: boolean default: true secrets: npm_token: required: false - env: NODE_VERSION: 22 - NPM_SCOPE: '@stoe' - + NPM_SCOPE: "@stoe" jobs: publish_npm: name: Publish to NPM if: ${{ inputs.npm }} - runs-on: ubuntu-latest - concurrency: group: ${{ github.workflow }}-npm-${{ github.ref }} cancel-in-progress: true - permissions: contents: read packages: write id-token: write - env: CI: true NODE_AUTH_TOKEN: ${{ secrets.npm_token }} - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 - name: Setup Node.js - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ env.NODE_VERSION }} + node-version: 24 scope: ${{ env.NPM_SCOPE }} - registry-url: 'https://registry.npmjs.org' - + registry-url: https://registry.npmjs.org - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile git ls-files -z . | xargs -0 git update-index --assume-unchanged - - name: NPM publish run: npm publish --provenance --access public --workspaces - publish_gh: name: Publish to GitHub if: ${{ inputs.gh }} - runs-on: ubuntu-latest - concurrency: group: ${{ github.workflow }}-gh-${{ github.ref }} cancel-in-progress: true - permissions: contents: read packages: write - env: CI: true NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - steps: - name: Checkout - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 - name: Setup Node.js - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 + uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 with: - node-version: ${{ env.NODE_VERSION }} + node-version: 24 scope: ${{ env.NPM_SCOPE }} - registry-url: 'https://npm.pkg.github.com' - + registry-url: https://npm.pkg.github.com - name: NPM config run: | npm pkg delete scripts.prepare npm install --ignore-scripts --pure-lockfile git ls-files -z . | xargs -0 git update-index --assume-unchanged - - name: GitHub Packages publish run: npm publish --access public --workspaces