From faea831befc5e7559f4ecf6217dc1955159973cb Mon Sep 17 00:00:00 2001 From: Latte Date: Sat, 7 Mar 2026 16:41:46 +0100 Subject: [PATCH] Add Coffee Notes collection and page --- src/components/Nav.astro | 1 + src/content/coffee/late-night-systems.md | 11 + src/content/coffee/learning-by-breaking.md | 11 + src/content/coffee/privacy-as-care.md | 12 + .../coffee/small-sites-still-matter.md | 12 + src/content/config.ts | 11 +- src/pages/coffee.astro | 315 ++++++++++++++++++ 7 files changed, 372 insertions(+), 1 deletion(-) create mode 100644 src/content/coffee/late-night-systems.md create mode 100644 src/content/coffee/learning-by-breaking.md create mode 100644 src/content/coffee/privacy-as-care.md create mode 100644 src/content/coffee/small-sites-still-matter.md create mode 100644 src/pages/coffee.astro diff --git a/src/components/Nav.astro b/src/components/Nav.astro index 1619875..b4ee38f 100644 --- a/src/components/Nav.astro +++ b/src/components/Nav.astro @@ -10,6 +10,7 @@ const links = [ { href: "/now", label: "now" }, { href: "/uses", label: "uses" }, { href: "/blog", label: "blog" }, + { href: "/coffee", label: "coffee" }, { href: "/changelog", label: "changelog" }, ]; diff --git a/src/content/coffee/late-night-systems.md b/src/content/coffee/late-night-systems.md new file mode 100644 index 0000000..095ff14 --- /dev/null +++ b/src/content/coffee/late-night-systems.md @@ -0,0 +1,11 @@ +--- +date: 2026-03-07T21:30:00Z +title: Late-night systems +draft: false +--- + +There is a very specific kind of peace in checking on a quiet system late at +night and finding that everything is simply humming along. + +No alerts. No drama. Just warm coffee, a few container logs, and the feeling +that the machines are behaving themselves for once. diff --git a/src/content/coffee/learning-by-breaking.md b/src/content/coffee/learning-by-breaking.md new file mode 100644 index 0000000..7403781 --- /dev/null +++ b/src/content/coffee/learning-by-breaking.md @@ -0,0 +1,11 @@ +--- +date: 2026-03-05T20:40:00Z +title: Learning by breaking +draft: false +--- + +One of the nicest things about a homelab is that it gives you permission to +learn by breaking things in a place that still feels like yours. + +Rebuild, retry, take notes, improve the backup story, and understand the system +a little better than you did the night before. diff --git a/src/content/coffee/privacy-as-care.md b/src/content/coffee/privacy-as-care.md new file mode 100644 index 0000000..0e83ece --- /dev/null +++ b/src/content/coffee/privacy-as-care.md @@ -0,0 +1,12 @@ +--- +date: 2026-03-06T23:10:00Z +title: Privacy as care +draft: false +--- + +Privacy is often framed like fear, but most of the time I experience it more as +care. + +Care for my own data. Care for other people's attention. Care for building +systems that do not assume they are entitled to watch everyone who walks +through the door. diff --git a/src/content/coffee/small-sites-still-matter.md b/src/content/coffee/small-sites-still-matter.md new file mode 100644 index 0000000..280acff --- /dev/null +++ b/src/content/coffee/small-sites-still-matter.md @@ -0,0 +1,12 @@ +--- +date: 2026-03-07T18:05:00Z +title: Small sites still matter +draft: false +--- + +I still think small personal websites matter because they let a person sound +like themselves again. + +Not every thought needs to be flattened into a post that fights for reach. Some +things are better when they can just quietly exist on a page someone made on +purpose. diff --git a/src/content/config.ts b/src/content/config.ts index 8e238b9..e86ca9b 100644 --- a/src/content/config.ts +++ b/src/content/config.ts @@ -17,4 +17,13 @@ const blog = defineCollection({ }), }); -export const collections = { blog }; +const coffee = defineCollection({ + type: "content", + schema: z.object({ + title: z.string().optional(), + date: z.coerce.date(), + draft: z.boolean().optional().default(false), + }), +}); + +export const collections = { blog, coffee }; diff --git a/src/pages/coffee.astro b/src/pages/coffee.astro new file mode 100644 index 0000000..36fe56a --- /dev/null +++ b/src/pages/coffee.astro @@ -0,0 +1,315 @@ +--- +import BaseLayout from "../layouts/BaseLayout.astro"; +import { getCollection } from "astro:content"; + +const coffeeEntries = (await getCollection("coffee", ({ data }) => !data.draft)) + .sort((a, b) => b.data.date.valueOf() - a.data.date.valueOf()); + +const renderedEntries = await Promise.all( + coffeeEntries.map(async (entry) => { + const { Content } = await entry.render(); + + return { + ...entry, + Content, + }; + }), +); + +function formatTimestamp(date: Date) { + const iso = date.toISOString(); + return `${iso.slice(0, 10)} ${iso.slice(11, 16)} UTC`; +} +--- + + + + +
+
+
+

Small reflections

+

Coffee Notes

+
==============================
+

+ These are shorter notes than the blog. Small thoughts, + building notes, privacy reflections, and quiet little things + written down while the coffee is still warm. +

+
+ + { + renderedEntries.length === 0 ? ( +
+

+ No notes yet. The mug is here, the notebook is just + still blank. +

+
+ ) : ( +
+

+ Coffee Notes entries +

+
    + {renderedEntries.map((entry) => ( +
  1. + +
    + {entry.data.title && ( +

    + {entry.data.title} +

    + )} +
    + +
    +
    +
  2. + ))} +
+
+ ) + } + +
+

Made with love by Latte

+
+
+
+
+ + -- 2.52.0