feat(site): SEO/agent-readiness, author footer, custom domain + Pages… #1
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 book to GitHub Pages | |
| # Builds the static site from content/ with site/generate.py and publishes site/ | |
| # to GitHub Pages. The committed images (cover, og-image, icons) are shipped as-is; | |
| # generate.py refreshes the HTML, sitemap, robots, manifest and llms files. | |
| on: | |
| push: | |
| branches: [main] | |
| paths: | |
| - "site/**" | |
| - "content/**" | |
| - "assets/**" | |
| - "scripts/**" | |
| - ".github/workflows/deploy-pages.yml" | |
| workflow_dispatch: | |
| # Least-privilege token; Pages deployment needs pages:write + id-token:write. | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| # Allow one concurrent deployment; let in-progress production deploys finish. | |
| concurrency: | |
| group: pages | |
| cancel-in-progress: false | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| - name: Regenerate site from content | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install pyyaml | |
| python site/generate.py | |
| - name: Configure Pages | |
| uses: actions/configure-pages@v5 | |
| with: | |
| enablement: true | |
| - name: Upload site artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: site | |
| deploy: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |