news-digest: add world + local headlines sections
Two new dense headline rails above the existing reddit/tech cards.
Designed for high-volume "what happened" coverage where the title
is the deliverable — no LLM summarization, ~15 items per section,
6-column-collapsing grid (title / source / time).
Digest pipeline:
* fetch_miniflux_headlines(category) — flat list per category, dedup
by lowercased title (different feeds syndicate the same wire stories)
* 8h look-back window (vs 12h for tech/reddit) since headlines move
faster
* cap of 15 per section (DIGEST_MINIFLUX_HEADLINES_MAX)
Frontend:
* .headline element parallels .item for the hide-button machinery
(both have data-id, both honored by app.js)
* dense 3-col layout collapses to 1-col on narrow screens
* jumpnav now numbers world=01, local=02, reddit=03, tech=04
Setup:
* seed-headlines.py — one-shot script (lives in the image at
/app/seed-headlines.py). Creates the World + Local categories in
miniflux, subscribes a curated feed list, and renames each feed
to a short display title (BBC vs "BBC News", "LA Times" vs "California").
Idempotent — reruns only add new feeds.
* Default world: BBC, NPR, Al Jazeera. Default local: LA Times Local,
LA Times CA, Voice of OC. (OC Register blocks miniflux; left out.)
* entrypoint.sh now syncs templates/{style.css,app.js,favicon.svg}
to /output on container start so frontend asset updates land
without a manual copy after rebuild.
This commit is contained in:
@@ -13,6 +13,16 @@ set -e
|
||||
|
||||
mkdir -p /output
|
||||
|
||||
# Sync static frontend assets from /app/templates → /output. The web
|
||||
# container serves /output as static; the assets are baked into the
|
||||
# image but the bind-mounted /output otherwise wouldn't pick up
|
||||
# CSS/JS updates on rebuild without a manual copy.
|
||||
for asset in style.css app.js favicon.svg; do
|
||||
if [ -f "/app/templates/$asset" ]; then
|
||||
cp -f "/app/templates/$asset" "/output/$asset"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ ! -f /output/index.html ]; then
|
||||
echo "[entrypoint] no /output/index.html yet — running first digest"
|
||||
/usr/local/bin/run-digest.sh || \
|
||||
|
||||
Reference in New Issue
Block a user