Skip to content

posts: link a blog post as <post:slug>, held to what the blog has published - #120

Merged
aledbf merged 1 commit into
mainfrom
infra-post-links
Nov 19, 2026
Merged

aledbf merged 1 commit into
mainfrom
infra-post-links

Conversation

@aledbf

@aledbf aledbf commented Nov 19, 2026

Copy link
Copy Markdown
Member

AGENTS.md asks a page to link a post where it would explain a reason; this gives the link a form the build checks, as <feature:…> does for the board.

  • [why](<post:the-slug>) becomes https://blog.spinbox.dev/posts/<slug>/, with the post's title (src/lib/post-links.mjs, rehype), and the same in the Markdown twins, llms-full.txt included (src/lib/pages.ts).
  • The build fails on a slug that is not in src/data/posts.json: the posts the blog's feed lists, written by task posts (tools/posts), which sources:bump now runs, so the daily sync rewrites it. The build reads the file, never the feed.
  • A feed that cannot be read keeps the file as it is (and writes one with no posts where there is none). The feed answers today with no items, so the list is empty and no page links a post.
  • Tests: tools/posts (the feed read, the feed unreachable, a feed of another shape) and src/lib/post-links.test.mjs, run by node --test in the gate.
  • README paragraph and AGENTS.md line on how to link a post.

🤖 Generated with Claude Code

…lished

A page that would explain a reason links the post that does: [why](<post:the-slug>). The build
points it at blog.spinbox.dev/posts/<slug>/ and fails on a slug that is not in src/data/posts.json,
which task posts writes from the blog's feed and the daily sync rewrites. A feed that cannot be
read keeps the file; the build never reads the feed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@aledbf
aledbf merged commit fc21e23 into main Nov 19, 2026
2 checks passed
@aledbf
aledbf deleted the infra-post-links branch November 19, 2026 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant