-
Notifications
You must be signed in to change notification settings - Fork 5
50 lines (45 loc) · 1.78 KB
/
Copy pathdeploy-web.yml
File metadata and controls
50 lines (45 loc) · 1.78 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
name: Deploy web showcase to GitHub Pages
# Publishes the static showcase site under `web/` to GitHub Pages via
# GitHub Actions. The site is plain HTML / CSS / JS + generated showcase
# assets — no build step. It replaced the old "deploy from branch /docs"
# setup when the showcase moved out of docs/ into web/ so that docs/ holds
# documentation only.
#
# REQUIRES: repository Settings → Pages → Source = "GitHub Actions"
# (one-time switch from "Deploy from a branch"). Until that switch is made,
# this workflow builds the artifact but Pages keeps serving the old source.
#
# Triggers: every push to `main` (no `paths` filter). `main` is only pushed at
# releases / hotfixes, so deploying unconditionally is cheap and correct — the
# v1.8.0 release fast-forwarded `main` with 67 changed `web/` files yet the old
# `paths: web/**` filter silently skipped the deploy, leaving the live site on
# the previous release. A `v*` tag trigger was tried as a backup but removed:
# GitHub Pages refuses to deploy from a tag ref (the `github-pages` environment
# only allows `main`), so it failed every release without ever deploying — and
# via `cancel-in-progress` could even cancel the good `main` run. The
# unconditional `main` trigger covers releases reliably on its own.
on:
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: true
jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- uses: actions/checkout@v7
- uses: actions/configure-pages@v6
- uses: actions/upload-pages-artifact@v5
with:
path: web
- id: deployment
uses: actions/deploy-pages@v5