Docs #216
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: # zizmor: ignore[dangerous-triggers] | |
| push: | |
| branches: [main] | |
| paths: | |
| - packages/typestats-site/docs/** | |
| - .github/workflows/docs.yml | |
| - packages/typestats-site/projects.toml | |
| - uv.lock | |
| - packages/typestats-site/zensical.toml | |
| - packages/typestats-site/src/typestats_site/dashboard.py | |
| - packages/typestats-site/src/typestats_site/templates/** | |
| workflow_run: | |
| workflows: [Collect] | |
| types: [completed] | |
| branches: [main] | |
| workflow_dispatch: | |
| permissions: | |
| contents: read # checkout | |
| concurrency: | |
| group: pages | |
| cancel-in-progress: false | |
| jobs: | |
| deploy: | |
| name: deploy | |
| if: github.event_name != 'workflow_run' || github.event.workflow_run.conclusion == 'success' | |
| permissions: | |
| pages: write # deploy to GitHub Pages | |
| id-token: write # verify the deployment originates from this workflow | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - name: checkout main | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: checkout data | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| ref: data | |
| path: _data | |
| persist-credentials: false | |
| - uses: actions/configure-pages@45bfe0192ca1faeb007ade9deae92b16b8254a0d # v6.0.0 | |
| - uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0 | |
| with: | |
| python-version: "3.14" | |
| - name: build dashboard pages | |
| run: >- | |
| uv run -m typestats_site | |
| dashboard | |
| --data-dir _data/reports | |
| --site-dir packages/typestats-site/_site | |
| --projects packages/typestats-site/projects.toml | |
| - name: build site | |
| run: >- | |
| uv run zensical build | |
| --config-file packages/typestats-site/zensical.toml | |
| --clean | |
| - uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0 | |
| with: | |
| path: packages/typestats-site/site | |
| - id: deployment | |
| uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0 |