|
1 | | -name: Publish Doc |
2 | | - |
3 | | -on: workflow_dispatch |
4 | | - |
5 | | -permissions: |
6 | | - contents: read |
7 | | - pages: write |
8 | | - id-token: write |
9 | | - |
10 | | -concurrency: |
11 | | - group: pages |
12 | | - cancel-in-progress: false |
13 | | - |
14 | | -jobs: |
15 | | - build: |
16 | | - runs-on: ubuntu-latest |
17 | | - steps: |
18 | | - - name: Checkout |
19 | | - uses: actions/checkout@v5 |
20 | | - with: |
21 | | - fetch-depth: 0 |
22 | | - |
23 | | - - name: Setup Node |
24 | | - uses: actions/setup-node@v5 |
25 | | - with: |
26 | | - node-version: 22 |
27 | | - cache: npm |
28 | | - cache-dependency-path: docs/package-lock.json |
29 | | - - name: Setup Pages |
30 | | - uses: actions/configure-pages@v5 |
31 | | - |
32 | | - - name: Install dependencies |
33 | | - working-directory: docs |
34 | | - run: npm ci |
35 | | - |
36 | | - - name: Build with VitePress |
37 | | - working-directory: docs |
38 | | - run: npm run docs:build |
39 | | - |
40 | | - - name: Upload artifact |
41 | | - uses: actions/upload-pages-artifact@v4 |
42 | | - with: |
43 | | - path: docs/.vitepress/dist |
44 | | - |
45 | | - deploy: |
46 | | - environment: |
47 | | - name: github-pages |
48 | | - url: ${{ steps.deployment.outputs.page_url }} |
49 | | - needs: build |
50 | | - runs-on: ubuntu-latest |
51 | | - name: Deploy |
52 | | - steps: |
53 | | - - name: Deploy to GitHub Pages |
54 | | - id: deployment |
55 | | - uses: actions/deploy-pages@v4 |
| 1 | +name: Publish Doc |
| 2 | + |
| 3 | +on: |
| 4 | + workflow_dispatch: |
| 5 | + workflow_call: |
| 6 | + |
| 7 | +permissions: |
| 8 | + contents: read |
| 9 | + pages: write |
| 10 | + id-token: write |
| 11 | + |
| 12 | +concurrency: |
| 13 | + group: pages |
| 14 | + cancel-in-progress: false |
| 15 | + |
| 16 | +jobs: |
| 17 | + build: |
| 18 | + runs-on: ubuntu-latest |
| 19 | + steps: |
| 20 | + - name: Checkout |
| 21 | + uses: actions/checkout@v5 |
| 22 | + with: |
| 23 | + fetch-depth: 0 |
| 24 | + |
| 25 | + - name: Setup Node |
| 26 | + uses: actions/setup-node@v5 |
| 27 | + with: |
| 28 | + node-version: 22 |
| 29 | + cache: npm |
| 30 | + cache-dependency-path: docs/package-lock.json |
| 31 | + - name: Setup Pages |
| 32 | + uses: actions/configure-pages@v5 |
| 33 | + |
| 34 | + - name: Install dependencies |
| 35 | + working-directory: docs |
| 36 | + run: npm ci |
| 37 | + |
| 38 | + - name: Build with VitePress |
| 39 | + working-directory: docs |
| 40 | + run: npm run docs:build |
| 41 | + |
| 42 | + - name: Upload artifact |
| 43 | + uses: actions/upload-pages-artifact@v4 |
| 44 | + with: |
| 45 | + path: docs/.vitepress/dist |
| 46 | + |
| 47 | + deploy: |
| 48 | + environment: |
| 49 | + name: github-pages |
| 50 | + url: ${{ steps.deployment.outputs.page_url }} |
| 51 | + needs: build |
| 52 | + runs-on: ubuntu-latest |
| 53 | + name: Deploy |
| 54 | + steps: |
| 55 | + - name: Deploy to GitHub Pages |
| 56 | + id: deployment |
| 57 | + uses: actions/deploy-pages@v4 |
0 commit comments