Pick any line to see why it is the way it is: the commit, the pull request and issue it came from, and what the agent was thinking.
| Merge platform pause and the hourly usage watcher: staff can pause compute, schedules, indexing or renders for everyone, the watcher emails on a breach and is never blind quietly, and the models proxy holds each run to its cap (billing 0051, integrations 0006) | 1 | /** |
| 2 | * While rendering is paused across g1t (billing's `platform_pause`, | |
| The docs folder is gone, and what it held lives where people read it: how a self-hosted g1t runs and how to deploy g1t to Cloudflare are pages on docs.g1t.sh under Run g1t yourself, and speed, rate limits and operating g1t.sh are sections of CONTRIBUTING.md; code that cited a file in docs/ now points to the page or section that covers it, or says what it means itself, and applied migrations and the runner images are left as they were. | 3 | * `renders`; docs.g1t.sh/guides/deploy-to-cloudflare/#spend-guardrails), no |
| 4 | * card is drawn: a request that misses the edge cache gets the brand card | |
| 5 | * the cache already has, or a redirect to g1t's static logo. Either is kept | |
| 6 | * only a minute, so cards come back soon after rendering is resumed. | |
| Merge platform pause and the hourly usage watcher: staff can pause compute, schedules, indexing or renders for everyone, the watcher emails on a breach and is never blind quietly, and the models proxy holds each run to its cap (billing 0051, integrations 0006) | 7 | */ |
| 8 | ||
| 9 | /** g1t's logo on dark, served by the site as a static file. */ | |
| 10 | export const STATIC_CARD = "https://g1t.sh/brand/g1t-logo-on-dark.png"; | |
| 11 | ||
| 12 | const PAUSED_CACHE_CONTROL = "public, max-age=60"; | |
| 13 | ||
| 14 | /** What a cache miss is answered with while renders are paused. */ | |
| 15 | export function pausedCard(brand: Response | undefined): Response { | |
| 16 | if (brand) { | |
| 17 | const response = new Response(brand.body, brand); | |
| 18 | response.headers.set("cache-control", PAUSED_CACHE_CONTROL); | |
| 19 | return response; | |
| 20 | } | |
| 21 | return new Response(null, { | |
| 22 | status: 302, | |
| 23 | headers: { location: STATIC_CARD, "cache-control": PAUSED_CACHE_CONTROL, "access-control-allow-origin": "*" }, | |
| 24 | }); | |
| 25 | } |
This file's history is long; its oldest lines are credited to the oldest commit read.