Build homepage from blog content index
Some checks are pending
Build / build (push) Waiting to run

This commit is contained in:
Neeldhara Misra 2026-06-22 13:09:14 +05:30
parent 02e47cf5d0
commit 9074e1884b
4 changed files with 481 additions and 42 deletions

View file

@ -2,10 +2,35 @@
Minimal static homepage for `neeldhara.blog`.
The build script fetches the RSS feed from each blog and writes `dist/index.html`
with the latest two entries per blog. It also copies the bundled Heliotrope
fonts into `dist/webfonts/`.
The build script reads local Markdown content from `../allblogs/sites/*` when
that sibling repo exists. In standalone Docker/Dokploy builds, it falls back to
the committed `content/blog-index.json`.
Each blog section shows:
- one optional fixed featured post marked with `main-feature: true`
- the two most recent non-featured posts by `pubDate`
It also copies the bundled Heliotrope fonts into `dist/webfonts/`.
```sh
npm run build
```
Refresh the committed content index from the sibling `allblogs` repo with:
```sh
npm run refresh:index
```
To force a build from the committed index, use:
```sh
BLOG_HOME_CONTENT_SOURCE=index npm run build
```
Use this frontmatter key on at most one post per blog:
```yaml
main-feature: true
```