Skip to content

[core] Port https://github.com/rjsf-team/react-jsonschema-form/pull/4745 #298

[core] Port https://github.com/rjsf-team/react-jsonschema-form/pull/4745

[core] Port https://github.com/rjsf-team/react-jsonschema-form/pull/4745 #298

name: Version and Publish
on:
workflow_dispatch:
push:
branches:
- main
concurrency: ${{ github.workflow }}-${{ github.ref }}
permissions:
id-token: write
contents: write
pull-requests: write
env:
PLAYWRIGHT_VERSION: "1.52.0"
jobs:
version:
timeout-minutes: 15
runs-on: ubuntu-latest
steps:
- name: Checkout code repository
uses: actions/checkout@v4
- name: Setup pnpm
uses: pnpm/action-setup@v4
- name: Setup node
uses: actions/setup-node@v4
with:
node-version: '24.3.x'
cache: pnpm
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Cache Playwright browser binaries
uses: actions/cache@v4
id: playwright-cache
with:
path: "~/.cache/ms-playwright"
key: "${{ runner.os }}-playwright-${{ env.PLAYWRIGHT_VERSION }}"
restore-keys: |
${{ runner.os }}-playwright-
- name: Install Playwright Browsers
if: steps.playwright-cache.outputs.cache-hit != 'true'
run: pnpx playwright@${PLAYWRIGHT_VERSION} install chromium --with-deps
- name: Cache turbo build setup
uses: actions/cache@v4
with:
path: .turbo
key: ${{ runner.os }}-turbo-${{ github.sha }}
restore-keys: |
${{ runner.os }}-turbo-
- name: Build
run: pnpm run ci:build --filter="@sjsf/*"
- name: Create and publish versions
uses: changesets/action@v1
with:
version: pnpm ci:version
publish: pnpm exec changeset publish
commit: "[build] release"
title: "[build] release"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}