Skip to content
name: Integrate (and Release)
on:
pull_request:
push:
branches:
- main
paths:
- 'packages/react-router-busy/**'
jobs:
quality:
if: github.repository == 'bitofbreeze/mono'
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Set up Biome
uses: biomejs/setup-biome@v2
with:
version: latest
- name: Run Biome
run: biome ci .
integrate:
needs: [quality]
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Bun
uses: oven-sh/[email protected]
with:
bun-version: latest
- name: Install dependencies (`npm ci`)
run: bun install --frozen-lockfile
- name: Test
run: bun test --filter react-router-busy --coverage
# Build checks types so no need for separate typecheck step
- name: Build
run: bun --filter react-router-busy build
- name: Check exports
run: bun --filter react-router-busy check-exports
release:
# Only upsert release PR when pushing (to main)
if: github.event_name == 'push'
needs: [integrate]
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Bun
uses: oven-sh/[email protected]
with:
bun-version: latest
- name: Install dependencies (`npm ci`)
run: bun install --frozen-lockfile
- name: Create release pull request or publish to npm
id: changesets
uses: changesets/action@v1
with:
# This expects you to have a script called release which does a build for your packages and calls changeset publish
publish: bun --filter react-router-busy build && bun --filter react-router-busy release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}