WIP Added canonical URL to head #60
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Deploy VitePress site | |
| on: | |
| push: | |
| branches: | |
| - main | |
| permissions: | |
| contents: write | |
| pages: write | |
| id-token: write | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - name: Install dependencies | |
| run: npm ci | |
| working-directory: docs | |
| - name: Install ApiGen (PHAR) | |
| run: | | |
| mkdir -p tools | |
| curl -L https://github.com/ApiGen/ApiGen/releases/latest/download/apigen.phar -o tools/apigen | |
| chmod +x tools/apigen | |
| - name: Generate API Documentation | |
| run: | | |
| tools/apigen -c apigen.neon | |
| - name: Build VitePress site | |
| run: npm run build | |
| working-directory: docs | |
| - name: Deploy to GitHub Pages | |
| uses: peaceiris/actions-gh-pages@v4 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: docs/.vitepress/dist | |
| keep_files: true |