Skip to content

Commit 433a2ed

Browse files
authored
feat: read generated release notes from the site
1 parent 16505f9 commit 433a2ed

15 files changed

Lines changed: 454 additions & 31 deletions

‎.github/workflows/ci.yml‎

Lines changed: 56 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: CI
22

33
on:
44
pull_request:
5+
types: [opened, synchronize, reopened, edited]
56
push:
67
branches: [master]
78
workflow_dispatch:
@@ -19,11 +20,26 @@ concurrency:
1920
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
2021

2122
jobs:
23+
title:
24+
if: github.event_name == 'pull_request'
25+
runs-on: ubuntu-latest
26+
steps:
27+
- uses: actions/checkout@v4
28+
- uses: actions/setup-node@v4
29+
with:
30+
node-version: "22"
31+
- run: node scripts/release.mjs title
32+
env:
33+
PR_TITLE: ${{ github.event.pull_request.title }}
34+
2235
check:
2336
name: repo gate
2437
runs-on: ubuntu-latest
2538
steps:
2639
- uses: actions/checkout@v4
40+
with:
41+
fetch-depth: 0
42+
ref: ${{ github.event.pull_request.head.sha || github.sha }}
2743
- uses: actions/setup-node@v4
2844
with:
2945
node-version: "22"
@@ -33,6 +49,8 @@ jobs:
3349
run: ./scripts/check.sh
3450
- name: Dry-run actual Worker publication and committed public artifact without credentials
3551
run: node scripts/deploy.mjs --preflight
52+
env:
53+
SOURCE_SHA: ${{ github.event.pull_request.head.sha || github.sha }}
3654

3755
deploy:
3856
name: production deploy and smoke
@@ -42,6 +60,8 @@ jobs:
4260
timeout-minutes: 20
4361
steps:
4462
- uses: actions/checkout@v4
63+
with:
64+
fetch-depth: 0
4565
- uses: actions/setup-node@v4
4666
with:
4767
node-version: "22"
@@ -59,12 +79,45 @@ jobs:
5979
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
6080
run: node scripts/deploy.mjs
6181

82+
release:
83+
needs: [check, deploy]
84+
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
85+
runs-on: ubuntu-latest
86+
permissions:
87+
contents: write
88+
pull-requests: write
89+
actions: write
90+
env:
91+
GH_TOKEN: ${{ github.token }}
92+
steps:
93+
- uses: actions/checkout@v4
94+
with:
95+
fetch-depth: 0
96+
persist-credentials: false
97+
- uses: actions/setup-node@v4
98+
with:
99+
node-version: "22"
100+
- name: Refuse unverified or superseded source
101+
id: source
102+
run: node scripts/release.mjs current
103+
env:
104+
CHECK_RESULT: ${{ needs.check.result }}
105+
DEPLOY_RESULT: ${{ needs.deploy.result }}
106+
- uses: googleapis/release-please-action@45996ed1f6d02564a971a2fa1b5860e934307cf7 # v5.0.0
107+
if: steps.source.outputs.current == 'true'
108+
id: release
109+
- name: Approve real native CI for the generated PR
110+
if: steps.release.outputs.prs_created == 'true'
111+
run: node scripts/release.mjs approve-ci
112+
env:
113+
RELEASE_PR: ${{ steps.release.outputs.pr }}
114+
62115
alert:
63116
name: alert agent on production failure
64-
needs: [check, deploy]
117+
needs: [check, deploy, release]
65118
if: >-
66119
always() && github.ref == 'refs/heads/master' &&
67-
(needs.check.result == 'failure' || needs.deploy.result == 'failure')
120+
(needs.check.result == 'failure' || needs.deploy.result == 'failure' || needs.release.result == 'failure')
68121
runs-on: ubuntu-latest
69122
timeout-minutes: 2
70123
steps:
@@ -77,5 +130,6 @@ jobs:
77130
SENTRY_DSN: https://dd3f79d117806f5bbd934413add4ae9d@o4510313803677696.ingest.us.sentry.io/4510314423386112
78131
CHECK_RESULT: ${{ needs.check.result }}
79132
DEPLOY_RESULT: ${{ needs.deploy.result }}
133+
RELEASE_RESULT: ${{ needs.release.result }}
80134
ALERT_PROBE: ${{ inputs.alert_probe && 'yes' || 'no' }}
81135
run: node scripts/alert-deploy.mjs

‎.release-please-manifest.json‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
".": "0.0.0"
3+
}

‎README.md‎

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Personal site for phaedrus.io: an oversized cobalt portrait, one short line,
44
three links, and an accessible quote chyron. Static HTML, CSS, and JavaScript;
5-
no site build step. A pinned Wrangler CLI owns publication. Shared colors and controls come from
5+
no frontend framework. A pinned Wrangler CLI owns publication. Shared colors and controls come from
66
[`@misty-step/aesthetic`](https://github.com/misty-step/aesthetic), pinned to a
77
release tag; the approved poster layout and type scale are site-specific.
88

@@ -43,6 +43,16 @@ python3 -m http.server 4173 # or: open index.html
4343
`<link>`.
4444
- `bio.md` and `explore/` are local draft material unless explicitly promoted.
4545

46+
## Releases
47+
48+
`CHANGELOG.md`, version files, tags and GitHub Releases are generated by
49+
release-please. The [local decision](docs/adr/0001-generated-releases.md) links
50+
the shared convention and records the baseline. The homepage footer links to
51+
`/changelog`, rendered from the deployed commit's canonical notes and version
52+
by the existing artifact materializer. No GitHub requests run in the browser.
53+
Static source preview shows the template; use the materialized artifact or
54+
Wrangler for release-page delivery QA.
55+
4656
## Deploy
4757

4858
Reviewed merges to `master` publish automatically after the repo-owned gate.
@@ -56,7 +66,7 @@ whose enabled issue-stream workflows notify only `kaylee-alert-intake`.
5666
The Actions run retains the Worker deployment/version, prior deployment, and hashes.
5767

5868
Before merge, the credential-free CI gate runs `node scripts/deploy.mjs --preflight`.
59-
This materializes only the five approved public files from the exact Git revision
69+
This materializes only the five approved public files and generated changelog from the exact Git revision
6070
into a temporary artifact, invokes the actual pinned `wrangler deploy` command
6171
with only `--dry-run` added, and runs the production byte-for-byte asset smoke
6272
against the materialized files over loopback HTTP. Production runs that same
@@ -67,7 +77,7 @@ are never uploaded. Unsupported, stray, combined, or repeated CLI arguments fail
6777
before provider authentication or mutation. Native dry-run proves compilation
6878
and packaging, not provider authorization, activation or public delivery.
6979

70-
The artifact smoke covers five public files per domain (ten production byte
80+
The artifact smoke covers six public files per domain (twelve production byte
7181
checks). The retired Canary observer, configuration/health handlers, standalone
7282
telemetry service, and their environment consumption have been removed. There
7383
are no browser config requests or ingest credentials. Historical secret inventory
@@ -77,8 +87,10 @@ Provider authentication, current-master ownership, the exact active Worker versi
7787
tag, and real delivery on both domains remain trusted-main checks. After upload,
7888
delivery readiness is bounded to 60 seconds using unchanged URLs and exact-byte
7989
expectations. Only the prior HTTP-200 bytes observed immediately before publication
80-
may coexist temporarily with exact new bytes; any HTTP error, timeout or unknown
81-
content fails immediately. Old bytes are never accepted as success: all ten
90+
may coexist temporarily with exact new bytes. For a genuinely new path absent
91+
from the exact prior source, only its specifically observed prior 404 bytes may
92+
also remain pending. All other HTTP errors, timeouts or unknown content fail
93+
immediately. Prior bytes are never accepted as success: all twelve
8294
checks must match the new artifact before the job passes. There is no cache purge,
8395
DNS change, cache-busting-only proof or generic retry.
8496

‎changelog.html‎

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
6+
<title>Changelog — Phaedrus</title>
7+
<meta name="description" content="Release notes for phaedrus.io." />
8+
<link rel="canonical" href="https://phaedrus.io/changelog" />
9+
<script>
10+
try {
11+
const saved = localStorage.getItem("ae-mode");
12+
if (saved === "light" || saved === "dark") document.documentElement.dataset.aeMode = saved;
13+
} catch {}
14+
</script>
15+
<link rel="preconnect" href="https://fonts.googleapis.com" />
16+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
17+
<link href="https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600&display=swap" rel="stylesheet" />
18+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/misty-step/aesthetic@v0.25.0/aesthetic.css"
19+
integrity="sha384-SrhwZwmgRlmOW+wK+CaZcarD/NCTFypxEUIxAaMxAP4vlBX15QTCqxagjT81KBZf" crossorigin="anonymous" />
20+
<style>
21+
:root { --ae-font: "Space Grotesk", Arial, sans-serif; font-synthesis: none; }
22+
body { max-width: 52rem; margin-inline: auto; padding: clamp(24px, 6vw, 72px); overflow-wrap: anywhere; }
23+
nav { margin-bottom: var(--ae-space-8); }
24+
nav a { display: inline-flex; align-items: center; min-height: 44px; }
25+
h1 { font-size: clamp(36px, 8vw, 64px); letter-spacing: -0.05em; }
26+
h2 { margin-top: var(--ae-space-10); padding-top: var(--ae-space-6); border-top: 1px solid var(--ae-line); }
27+
h3 { margin-top: var(--ae-space-6); }
28+
p { margin-block: var(--ae-space-3); line-height: 1.7; }
29+
.identity { color: var(--ae-ink-muted); font-size: 13px; margin-block: var(--ae-space-4) var(--ae-space-8); }
30+
.change { padding-left: var(--ae-space-4); border-left: 2px solid var(--ae-line); }
31+
</style>
32+
</head>
33+
<body>
34+
<nav aria-label="Site"><a href="/">← Phaedrus</a></nav>
35+
<main>
36+
<h1>Changelog</h1>
37+
<p class="identity"><!-- release --></p>
38+
<!-- notes -->
39+
</main>
40+
</body>
41+
</html>
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Generated releases for the public site
2+
3+
Accepted: 2026-10-15.
4+
5+
One release unit: the public `vanity` Worker and its allowlisted static assets.
6+
Use the [shared release convention](https://github.com/misty-step/harness/blob/master/docs/release-convention.md)
7+
and [Foundations](https://foundations.mistystep.io/), not a second local policy.
8+
9+
No previous tags or GitHub Releases exist. Adopt release-please's Node strategy
10+
at baseline `16505f9d2698c2b6a7191df1827eade8633a8b90`, with initial manifest
11+
and package version `0.0.0`. These are bootstrap state, not a published release.
12+
Use the generator's default first release, `1.0.0`; do not publish historical
13+
personal-site commit messages as retrospective notes.
14+
15+
The generated `CHANGELOG.md` is canonical. The existing exact-revision artifact
16+
materializer renders it into static `/changelog` beside its generated version
17+
and full source SHA. It uploads no new source, draft, private record or generator
18+
input. The homepage's small footer link leaves the three personal exits intact.
19+
The shipped page needs no GitHub token, API, new runtime or dependency.
20+
21+
Keep the existing repo gate, native dry-run, sole production deploy path,
22+
current-master check, active-provider identity readback, both-domain exact-byte
23+
smoke and Sentry agent intake. The same serialized CI run publishes metadata
24+
only after those gates succeed. Native approval starts only the release bot's
25+
current same-repository PR's configured CI and Allie workflows; neither dispatch
26+
checks nor passing stand-ins are used.
27+
28+
Code rollback uses Cloudflare's retained Worker versions and their associated
29+
static assets, followed by exact source smoke. It never restores data. There is
30+
no state store or migration in this release unit. A disposable Worker recovery
31+
drill is operator evidence, not a new scheduled gate or production restore.
32+
33+
`SPEC.md` is absent at adoption. `VISION.md` and the README currently describe
34+
the accepted page behavior; their observable stories are sampled rather than
35+
inventing a new product contract in release automation.

‎index.html‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,11 @@
198198
margin-top: var(--ae-space-5);
199199
font-size: 13px;
200200
}
201+
.quote-tools nav a {
202+
display: inline-flex;
203+
align-items: center;
204+
min-height: 44px;
205+
}
201206
.quote-tools .ae-mode {
202207
width: 44px;
203208
height: 44px;
@@ -359,6 +364,7 @@ <h1 id="name">Phaedrus</h1>
359364
</figcaption>
360365
</figure>
361366
<div class="quote-tools">
367+
<nav aria-label="Site"><a href="/changelog">Changelog</a></nav>
362368
<button
363369
class="ae-mode"
364370
id="mode"

‎package-lock.json‎

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"name": "vanity",
3+
"version": "0.0.0",
34
"private": true,
45
"engines": { "node": ">=22" },
56
"devDependencies": { "wrangler": "4.145.0" }

‎release-please-config.json‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
3+
"bootstrap-sha": "16505f9d2698c2b6a7191df1827eade8633a8b90",
4+
"packages": {
5+
".": {
6+
"release-type": "node",
7+
"include-component-in-tag": false
8+
}
9+
}
10+
}

‎scripts/alert-deploy.mjs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const event = {
2525
}] },
2626
fingerprint: ["vanity-deploy", process.env.GITHUB_RUN_ID, process.env.GITHUB_RUN_ATTEMPT],
2727
tags: { repository: "moomooskycow/vanity", alert_route_probe: probe ? "yes" : "no" },
28-
extra: { run_url: runUrl, check_result: process.env.CHECK_RESULT, deploy_result: process.env.DEPLOY_RESULT },
28+
extra: { run_url: runUrl, check_result: process.env.CHECK_RESULT, deploy_result: process.env.DEPLOY_RESULT, release_result: process.env.RELEASE_RESULT },
2929
};
3030
const response = await fetch(endpoint, {
3131
method: "POST",

0 commit comments

Comments
 (0)