meta: bump actions/checkout from 4 to 5 #42
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 and Generate Documentation | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| types: [opened, reopened, synchronize, ready_for_review] | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref || github.run_id }} | |
| cancel-in-progress: true | |
| jobs: | |
| build_and_deploy: | |
| if: github.event_name != 'pull_request' || !github.event.pull_request.draft | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Checkout source code | |
| uses: actions/checkout@v5 | |
| - name: Install nix | |
| uses: cachix/install-nix-action@v31 | |
| with: | |
| github_access_token: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Build docs | |
| run: | | |
| nix develop --command just preset=ci-ubuntu-gcc build_docs | |
| - name: Deploy docs | |
| uses: JamesIves/github-pages-deploy-action@v4 | |
| with: | |
| folder: build/docs/html | |
| commit-message: "docs: deploy documentation site" | |
| single-commit: true | |
| branch: gh-pages | |
| if: github.event_name == 'push' |