chore: manually trigger docs #18
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: Publish Docs | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| - 2.x | |
| - 1.x | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: false | |
| jobs: | |
| docs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install PIP Dependencies | |
| uses: actions/setup-python@v5 | |
| with: | |
| cache: 'pip' | |
| - run: | | |
| git fetch --tags | |
| cd docs | |
| python -m venv venv | |
| source venv/bin/activate | |
| python -m pip install uv sphinx-multiversion | |
| python -m pip install -r requirements.txt | |
| sphinx-multiversion . build | |
| - name: Setup Pages | |
| uses: actions/configure-pages@v5 | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: './docs/build' | |
| deploy: | |
| needs: docs | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |