mooncak397 Claude Opus 5.5 commited on
Commit ·
fd995a1
1
Parent(s): 4953424
web: GitHub Pages workflow (manual or push on web/**), needs Pages source = GitHub Actions
Browse files- .github/workflows/pages.yml +33 -0
.github/workflows/pages.yml
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Publishes web/ to GitHub Pages. Works only after Pages is set to "GitHub Actions" in the repo settings (docs/DEPLOY.md).
|
| 2 |
+
name: Pages
|
| 3 |
+
|
| 4 |
+
on:
|
| 5 |
+
push:
|
| 6 |
+
branches: [main]
|
| 7 |
+
paths: ['web/**']
|
| 8 |
+
workflow_dispatch:
|
| 9 |
+
|
| 10 |
+
permissions:
|
| 11 |
+
contents: read
|
| 12 |
+
pages: write
|
| 13 |
+
id-token: write
|
| 14 |
+
|
| 15 |
+
concurrency:
|
| 16 |
+
group: pages
|
| 17 |
+
cancel-in-progress: false
|
| 18 |
+
|
| 19 |
+
jobs:
|
| 20 |
+
deploy:
|
| 21 |
+
runs-on: ubuntu-latest
|
| 22 |
+
environment:
|
| 23 |
+
name: github-pages
|
| 24 |
+
url: ${{ steps.deployment.outputs.page_url }}
|
| 25 |
+
steps:
|
| 26 |
+
- uses: actions/checkout@v7
|
| 27 |
+
# the page needs no build step (ADR-004); leave out the local fake API and the folder README
|
| 28 |
+
- run: cp -r web _site && rm -rf _site/dev _site/README.md
|
| 29 |
+
- uses: actions/upload-pages-artifact@v5
|
| 30 |
+
with:
|
| 31 |
+
path: _site
|
| 32 |
+
- id: deployment
|
| 33 |
+
uses: actions/deploy-pages@v5
|