system-prompts-and-models-o.../.github/workflows/pages.yml
Claude 1d6009957f
Let the Pages workflow enable Pages itself
Both deploy runs failed at configure-pages with "Get Pages site failed …
Not Found": the repo had never had Pages turned on, so there was no Pages
site for the action to configure.

Set enablement: true so the action creates the Pages site via the API when
one does not exist, rather than requiring someone to visit Settings -> Pages
and pick the GitHub Actions source by hand. This also means a fresh fork of
this repo deploys without manual setup.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016F6MR5mdWYJmZJsZzE7rKu
2026-08-24 15:01:38 +00:00

50 lines
1.2 KiB
YAML

name: Deploy playbook to GitHub Pages
on:
push:
branches:
- main
- claude/repository-value-extraction-tqhu1s
paths:
- "site/**"
- ".github/workflows/pages.yml"
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment; let an in-flight deploy finish rather than
# cancelling it, so a half-published site is never left live.
concurrency:
group: pages
cancel-in-progress: false
jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Checkout
uses: actions/checkout@v4
# enablement: true turns Pages on via the API if it is not already
# enabled, so a fresh clone or fork of this repo deploys without anyone
# having to visit Settings -> Pages first.
- name: Configure Pages
uses: actions/configure-pages@v5
with:
enablement: true
- name: Upload site
uses: actions/upload-pages-artifact@v3
with:
path: site
- name: Deploy
id: deployment
uses: actions/deploy-pages@v4