Static blog site generator in one Go binary: Markdown in, self-contained semantic HTML out. No JavaScript, no database, minimal deps.

Pages (type: page) and footer links #17

Merged janantos.tngl.sh
targeting main from footerlinks
Merged opened by and assigned to janantos.tngl.sh
targeting main from footerlinks

Closes #1 (custom links in footer).

footerLinks: new optional config.json field, a list of {text, href} pairs rendered in the site footer after the home link. /… hrefs get the base-path prefix like every other internal link, scheme URLs (http/https/mailto/data) open in a new tab, entries with empty text or href are dropped, and an unset field leaves the footer byte-identical. Links are precomputed in tmpl.Render so every page (posts, index, archive, tags, 404) gets them.

type: page: new frontmatter field. Absent or post means post, so existing sites keep building unchanged; any other value is a hard error. A page gets its own /slug/ page (title as h1, no date line, no tags, no BlogPosting JSON-LD, OG type website) but is excluded from the home post list, /archive/, tags and feeds; the sitemap still lists it (undated pages get no lastmod). Pages sort by path for deterministic output, and an undated page has a zero Date instead of an mtime fallback, so the output does not depend on checkout times. Posts and pages share one URL space: duplicate-slug checks (build and validate) cover both, and the dev server serves pages too.

createsite now scaffolds imprint.md and privacy-policy.md as pages (no cookies / no data collected; imprint with an email placeholder for the owner) and points the scaffolded config's footerLinks at them, so a fresh site is legal out of the box. The showcase site gets the same two pages and footer links; the imprint still carries the email placeholder to be filled in.

Commits 0