just a website
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add 404 page and set wrangler config appropriately. Change runner for workflow and add AGENTS.md for LLM.

+120 -2
+1 -1
.github/workflows/deploy.yml
··· 5 5 - main 6 6 jobs: 7 7 deploy: 8 - runs-on: blacksmith-2vcpu-ubuntu-2404 8 + runs-on: blacksmith-4vcpu-ubuntu-2404-arm 9 9 steps: 10 10 - name: Check out repository 11 11 uses: actions/checkout@v4
+5
404.qmd
··· 1 + --- 2 + title: Page Not Found 3 + --- 4 + 5 + The page you have requested could not be found. 🤷
+113
AGENTS.md
··· 1 + # AGENTS.md 2 + 3 + Guidance for agents working on this repository. 4 + 5 + ## What this is 6 + 7 + A personal website at [rorylawless.com](https://rorylawless.com). It is a static site built with [Quarto](https://quarto.org), hosted on Cloudflare Workers. Content is written in `.qmd` (Quarto Markdown) files. Posts that include R code use `renv` for reproducible dependency management. 8 + 9 + **Agents are not expected to help with writing or editing content.** Work here is focused on look and feel, infrastructure, and tooling. 10 + 11 + --- 12 + 13 + ## Tech stack 14 + 15 + | Layer | Tool | 16 + |---|---| 17 + | Site framework | Quarto | 18 + | Styling | Custom SCSS (`assets/custom.scss`), no Quarto theme (`theme: none`) | 19 + | Hosting | Cloudflare Workers (static assets via Wrangler) | 20 + | CI/CD | GitHub Actions (`.github/workflows/deploy.yml`) | 21 + | R environment | renv | 22 + | Analytics | Simple Analytics | 23 + 24 + --- 25 + 26 + ## Repository layout 27 + 28 + ``` 29 + _quarto.yml # Master site configuration (colors, fonts, navbar, output dir) 30 + assets/ 31 + custom.scss # All custom styles — primary target for look and feel changes 32 + template.ejs # EJS template for the post listing on the homepage 33 + html/ 34 + analytics.html # Simple Analytics script injection 35 + posts/ # Blog posts, each in its own subdirectory with index.qmd 36 + _metadata.yml # Shared frontmatter defaults for all posts 37 + .well-known/ # PGP key and security.txt 38 + _redirects # Cloudflare redirect rules 39 + _headers # Cloudflare response header rules 40 + wrangler.jsonc # Cloudflare Workers deployment config 41 + package.json # Node deps (just wrangler) 42 + renv.lock # Locked R package versions 43 + .github/workflows/ 44 + deploy.yml # Build and deploy pipeline 45 + ``` 46 + 47 + Output goes to `_site/` (generated, not committed). The `_freeze/` directory caches R code execution results and is committed. 48 + 49 + --- 50 + 51 + ## Design system 52 + 53 + **Colors** (defined in `_quarto.yml`): 54 + - Navbar background: `#24617a` (teal) 55 + - Navbar / footer text: `#fbf5f5` (off-white) 56 + - Body text: `#070a0c` 57 + - Links: `#183e4d` 58 + 59 + **Fonts** (loaded from Google Fonts in `assets/custom.scss`): 60 + - Body: Lato 61 + - Navbar title: Playfair Display 62 + 63 + **Layout**: Max content width is controlled via `.navbar-container { width: 820px }` in `custom.scss`. The navbar title uses `font-size: 4vw` (viewport-relative). 64 + 65 + When changing look and feel, `assets/custom.scss` and `_quarto.yml` are the two files to focus on. Do not introduce a Quarto theme — the site intentionally uses `theme: none`. 66 + 67 + --- 68 + 69 + ## Build and deploy 70 + 71 + The site is never built locally — CI handles it. The full pipeline on push to `main`: 72 + 73 + 1. Restore cached `_freeze/` and `node_modules/` 74 + 2. Set up R + renv (restores packages from `renv.lock`) 75 + 3. Run `quarto render` → outputs to `_site/` 76 + 4. Run `wrangler deploy` → uploads `_site/` to Cloudflare Workers 77 + 78 + Secrets required: `CLOUDFLARE_ACCOUNT_ID`, `CLOUDFLARE_API_TOKEN` (stored in GitHub Actions). 79 + 80 + To preview changes locally you would need Quarto and R installed, then `quarto preview`. Agents working in this environment should not attempt to run the full build. 81 + 82 + --- 83 + 84 + ## Cloudflare configuration 85 + 86 + `wrangler.jsonc` defines: 87 + - Static assets served from `_site/` 88 + - `not_found_handling: "single-page-application"` — all 404s fall back to `index.html` 89 + - `html_handling: "auto-trailing-slash"` — URL normalisation 90 + - `placement: { mode: "smart" }` — Cloudflare automatic edge placement 91 + - Custom domain: `rorylawless.com` 92 + 93 + URL redirects live in `_redirects` (Cloudflare syntax). Response headers live in `_headers`. 94 + 95 + --- 96 + 97 + ## Conventions 98 + 99 + - Post directories use kebab-case naming (e.g., `posts/the-basics-of-duckdb-in-r/`) 100 + - Dates throughout are ISO 8601 (`2025-03-30`) 101 + - Reusable content snippets use Quarto's `{{< include >}}` shortcode 102 + - Draft posts are hidden via `drafts: gone` in `_quarto.yml` 103 + - Do not add search, categories, or sort UI to the post listing — the site is intentionally minimal 104 + 105 + --- 106 + 107 + ## What to avoid 108 + 109 + - Do not introduce a Quarto theme (Bootstrap-based) — styling is intentionally from scratch 110 + - Do not add JavaScript frameworks or bundlers 111 + - Do not commit the `_site/` output directory 112 + - Do not edit `.qmd` content files — content is out of scope for agents 113 + - Do not modify `renv.lock` manually — R package changes go through `renv`
+1 -1
wrangler.jsonc
··· 4 4 "assets": { 5 5 "directory": "./_site", 6 6 "html_handling": "auto-trailing-slash", 7 - "not_found_handling": "single-page-application" 7 + "not_found_handling": "404-page" 8 8 }, 9 9 "placement": { 10 10 "mode": "smart"