Website Update #631
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: Website Update | |
| on: | |
| schedule: | |
| - cron: '0 6 * * *' | |
| workflow_dispatch: | |
| workflow_run: | |
| workflows: | |
| - Run benchmarks | |
| types: | |
| - completed | |
| permissions: | |
| pages: write | |
| id-token: write | |
| contents: read | |
| jobs: | |
| generate_website: | |
| if: ${{ github.event_name != 'workflow_run' || github.event.workflow_run.conclusion == 'success' }} | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v7 | |
| - name: Fetch benchmark results | |
| run: | | |
| git fetch origin benchmark-results | |
| git checkout origin/benchmark-results -- results | |
| - name: Set up Python 3.12 | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.12' | |
| - name: Install dependencies | |
| run: | | |
| pip install --upgrade pip | |
| pip install --upgrade -r requirements_web.txt | |
| - name: Generate website | |
| run: python3 website-generator/generator.py --config ./setup/config.json | |
| - name: Upload pages artifact | |
| uses: actions/upload-pages-artifact@v5 | |
| with: | |
| path: docs | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v5 |