ci: reduce timeout-minutes from 10 to 5 #48
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: Docs | |
| on: | |
| push: | |
| branches: ['main'] | |
| tags: | |
| - '*' | |
| pull_request: | |
| branches: ['main'] | |
| permissions: | |
| contents: write | |
| pages: write | |
| id-token: write | |
| # Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. | |
| # However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. | |
| concurrency: | |
| group: 'pages' | |
| cancel-in-progress: false | |
| jobs: | |
| deploy: | |
| name: Build and deploy documentation | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v5 | |
| with: | |
| fetch-depth: 0 # fetch all commits/branches | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: false | |
| - name: Configure Git for GitHub Actions bot | |
| run: | | |
| git config --local user.name "github-actions[bot]" | |
| git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
| - name: Validate docs | |
| run: uv run -- mkdocs build --strict | |
| - name: Deploy dev docs | |
| if: github.ref == 'refs/heads/main' | |
| run: | | |
| uv run -- mike deploy --push --update-aliases dev | |
| - name: Deploy release docs | |
| if: github.ref_type == 'tag' | |
| run: | | |
| uv run -- mike deploy --push --update-aliases ${{ github.ref_name }} latest | |
| uv run -- mike set-default --push latest |