All checks were successful
Checking-doc / build-and-deploy (pull_request) Successful in 2m3s
42 lines
1.1 KiB
YAML
42 lines
1.1 KiB
YAML
name: Checking-doc
|
|
run-name: Checking doc — ${{ gitea.run_id }}
|
|
on:
|
|
workflow_dispatch:
|
|
pull_request:
|
|
types: [opened,synchronize]
|
|
|
|
jobs:
|
|
build-and-deploy:
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: read
|
|
deployments: write
|
|
steps:
|
|
- name: 🚚 Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- uses: pnpm/action-setup@v4
|
|
name: 🔧Install pnpm
|
|
with:
|
|
run_install: false
|
|
|
|
- name: 🔧Install Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 20
|
|
cache: 'pnpm'
|
|
|
|
- name: 🔧Install dependencies
|
|
run: pnpm install
|
|
|
|
- name: 🔴Build doc
|
|
run: pnpm run docs:build
|
|
|
|
- name: 🚀 Deploy to Cloudflare Pages
|
|
uses: cloudflare/wrangler-action@v3
|
|
with:
|
|
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
|
|
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
|
|
command: pages deploy ./src/.vuepress/dist --project-name=jingji-spbook |