Skip to content

chore: release main #1451

chore: release main

chore: release main #1451

Workflow file for this run

name: Inspect Pull Requests
on:
pull_request:
branches: [main]
jobs:
bundlesize:
if: ${{ always() && github.head_ref != 'release-please--branches--main' }}
needs: release-bundlesize
runs-on: ubuntu-latest
permissions:
pull-requests: write
strategy:
matrix:
node-version: [20.x]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
registry-url: "https://registry.npmjs.org"
- name: Setup PNPM
uses: pnpm/action-setup@v4
- name: Install Dependencies
run: pnpm install
- name: Build packages
run: npx lerna run build --ignore "@versini/example-*" --ignore @versini/documentation
- name: Run Bundle Size
run: |
npx lerna run stats:pr
npx lerna run stats:report
- name: Add PR Comment
uses: mshick/add-pr-comment@v2
if: always()
with:
refresh-message-position: true
message-path: |
packages/ui-components/tmp/pr-stats.md
packages/ui-fingerprint/tmp/pr-stats.md
packages/ui-form/tmp/pr-stats.md
packages/ui-system/tmp/pr-stats.md
inspect:
if: ${{ always() }}
needs: release-bundlesize
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20.x]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
registry-url: "https://registry.npmjs.org"
- name: Setup PNPM
uses: pnpm/action-setup@v4
- name: Install Dependencies
run: pnpm install
- name: Run Lint and Coverage
run: |
npx lerna run lint --ignore @versini/documentation
npx lerna run build --ignore @versini/documentation
npx lerna run test:coverage --ignore @versini/documentation
release-bundlesize:
if: github.head_ref == 'release-please--branches--main'
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
strategy:
matrix:
node-version: [20.x]
steps:
# secrets.GITHUB_TOKEN is used by default with "checkout",
# but in this case we are explicitely using a personal
# token with the same permissions (NODE_CLI).
# This is because we want to use the "release-please" action
# that updates and commit files. Other jobs should react to
# these commits and run.
# From GitHub docs: "When you use the repository's GITHUB_TOKEN
# to perform tasks on behalf of the GitHub Actions app, events
# triggered by the GITHUB_TOKEN will not create a new workflow
# run. This prevents you from accidentally creating recursive
# workflow runs.
- name: Checkout
uses: actions/checkout@v4
with:
token: ${{ secrets.NODE_CLI }}
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
registry-url: "https://registry.npmjs.org"
- name: Setup PNPM
uses: pnpm/action-setup@v4
- name: Install Dependencies
run: pnpm install
- name: Run Bundle Size For Release PR
run: |
npx lerna run build --ignore "@versini/example-*" --ignore @versini/documentation
npx lerna run stats:release
- name: Commit Release Stats to Release PR
uses: stefanzweifel/git-auto-commit-action@v5