CI / Lint (push) Canceled after 0s
CI / Build Test (stage-web) (push) Canceled after 0s
CI / Build Test (ui-loading-screens) (push) Canceled after 0s
CI / Build Test (ui-transitions) (push) Canceled after 0s
CI / Unit Test (push) Canceled after 0s
CI / Type Check (push) Canceled after 0s
CI / Check Provenance (push) Canceled after 0s
Sync Labels / sync-labels (push) Successful in 1m43s
- Remove stage-tamagotchi, stage-pocket, server, and engine workspaces with their workflows, addons, and docs - Switch the toolchain from pnpm to bun, replace lockfiles with bun.lock - Rewrite remaining product references to Moeka
145 lines
3.9 KiB
YAML
145 lines
3.9 KiB
YAML
name: CI
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
lint:
|
|
name: Lint
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
# NOTICE:
|
|
# Pin Node.js because 26.8.0 reports 26.8.0-alpha.0.0.0.
|
|
# sharp 0.29.3 rejects this prerelease version during bun install.
|
|
# Source: https://github.com/nodejs/node/blob/v26.8.0/src/node_version.h
|
|
# Remove this pin when Node.js 26 reports a stable version.
|
|
- uses: actions/setup-node@v6
|
|
with:
|
|
node-version: 26.7.0
|
|
|
|
- uses: oven-sh/setup-bun@v2
|
|
with:
|
|
bun-version: 1.4.2
|
|
|
|
- run: bun install --frozen-lockfile
|
|
- run: bun run lint
|
|
|
|
build-test:
|
|
name: Build Test (${{ matrix.app_name }})
|
|
if: ${{ !(github.event_name == 'pull_request' && startsWith(github.event.pull_request.head.label, 'moeru-ai:i18n/')) }}
|
|
strategy:
|
|
matrix:
|
|
include:
|
|
- app_name: stage-web
|
|
command: bun run --filter @proj-airi/stage-web build && bun run --filter @proj-airi/docs build:base && mv ./docs/.vitepress/dist ./apps/stage-web/dist/docs && bun run --filter @proj-airi/stage-ui story:build && mv ./packages/stage-ui/.histoire/dist ./apps/stage-web/dist/ui
|
|
|
|
- app_name: ui-transitions
|
|
command: bun run --filter @proj-airi/ui-transitions play:build
|
|
|
|
- app_name: ui-loading-screens
|
|
command: bun run --filter @proj-airi/ui-loading-screens play:build
|
|
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
# Turborepo
|
|
- name: Cache turbo build setup
|
|
uses: actions/cache@v5
|
|
with:
|
|
path: .turbo
|
|
key: ${{ runner.os }}-turbo-${{ github.sha }}
|
|
restore-keys: |
|
|
${{ runner.os }}-turbo-
|
|
|
|
- uses: actions/setup-node@v6
|
|
with:
|
|
node-version: 26.7.0
|
|
|
|
- uses: oven-sh/setup-bun@v2
|
|
with:
|
|
bun-version: 1.4.2
|
|
|
|
- run: bun install --frozen-lockfile
|
|
- run: bun run build:packages
|
|
|
|
- name: Build App
|
|
run: ${{ matrix.command }}
|
|
|
|
unit-test:
|
|
name: Unit Test
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
# Turborepo
|
|
- name: Cache turbo build setup
|
|
uses: actions/cache@v5
|
|
with:
|
|
path: .turbo
|
|
key: ${{ runner.os }}-turbo-${{ github.sha }}
|
|
restore-keys: |
|
|
${{ runner.os }}-turbo-
|
|
|
|
- uses: actions/setup-node@v6
|
|
with:
|
|
node-version: 26.7.0
|
|
|
|
- uses: oven-sh/setup-bun@v2
|
|
with:
|
|
bun-version: 1.4.2
|
|
|
|
- run: bun install --frozen-lockfile
|
|
|
|
- name: Setup Playwright
|
|
run: npx playwright install chromium
|
|
|
|
- run: bun run build:packages
|
|
- run: bun run test:run
|
|
env:
|
|
NODE_OPTIONS: --no-experimental-webstorage
|
|
|
|
typecheck:
|
|
name: Type Check
|
|
runs-on: ubuntu-latest
|
|
if: ${{ !(github.event_name == 'pull_request' && startsWith(github.event.pull_request.head.label, 'moeru-ai:i18n/')) }}
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
|
|
# Node.js
|
|
- uses: actions/setup-node@v6
|
|
with:
|
|
node-version: 26.7.0
|
|
|
|
- uses: oven-sh/setup-bun@v2
|
|
with:
|
|
bun-version: 1.4.2
|
|
|
|
- run: bun install --frozen-lockfile
|
|
- run: bun run typecheck
|
|
|
|
check-provenance:
|
|
name: Check Provenance
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
with:
|
|
fetch-depth: 0
|
|
- uses: danielroe/provenance-action@main
|
|
id: check
|
|
with:
|
|
fail-on-provenance-change: true # optional, default: false
|
|
# lockfile: bun.lock # optional
|
|
# base-ref: origin/main # optional, default: origin/main
|
|
# fail-on-downgrade: true # optional, default: true
|
|
- name: Print result
|
|
run: "echo 'Downgraded: ${{ steps.check.outputs.downgraded }}'"
|