mirror of
https://github.com/byoungd/up.git
synced 2026-10-27 07:03:09 +08:00
* Upgrade learning guide onboarding and maintenance * Clarify audit publication status --------- Co-authored-by: 你的名字 <you@example.com>
62 lines
1.5 KiB
YAML
62 lines
1.5 KiB
YAML
name: CI
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
branches: [main]
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
validate:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v7
|
|
- uses: actions/setup-node@v7
|
|
with:
|
|
node-version: 24
|
|
cache: npm
|
|
- uses: actions/setup-python@v6
|
|
with:
|
|
python-version: "3.12"
|
|
- uses: actions/setup-java@v4
|
|
with:
|
|
distribution: temurin
|
|
java-version: "21"
|
|
- run: npm ci
|
|
- run: python -m pip install -r requirements-pdf.txt
|
|
- run: python tests/pdf_layout_test.py
|
|
- run: npm audit --audit-level=high
|
|
- run: npm run check
|
|
- run: npm run book:validate
|
|
- run: npm run docs:build
|
|
- uses: actions/upload-artifact@v7
|
|
with:
|
|
name: site-preview
|
|
path: docs/.vitepress/dist/
|
|
retention-days: 14
|
|
- name: Generated files are committed
|
|
run: |
|
|
npm run sync:content
|
|
npm run book:pdf:check
|
|
git diff --exit-code
|
|
|
|
smoke:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v7
|
|
- uses: actions/setup-node@v7
|
|
with:
|
|
node-version: 24
|
|
cache: npm
|
|
- run: npm ci
|
|
- run: npx playwright install --with-deps chromium
|
|
- run: npm run test:smoke
|
|
- uses: actions/upload-artifact@v7
|
|
if: failure()
|
|
with:
|
|
name: playwright-report
|
|
path: playwright-report/
|
|
retention-days: 7
|