pub / newsplanet

Planet-Style Newsfeed generated with perlanet
git clone https://https://src.jayvii.de/pub/newsplanet.git
Home | Log | Files | Exports | Refs | README | RSS

commit d703f95812e0c04d4ee8f089e972a6ec49be3f52
parent 87c2e5c49bcda001b2bafdbbcab11af1693eb080
Author: JayVii <jayvii[AT]posteo[DOT]de>
Date:   Fri, 31 May 2024 22:17:02 +0200

Add Update time; Layout improvements

Diffstat:
Mconfig.yaml | 2+-
Arun.sh | 4++++
Mtemplate.html | 14++++++++------
3 files changed, 13 insertions(+), 7 deletions(-)

diff --git a/config.yaml b/config.yaml @@ -32,7 +32,7 @@ feeds: - url: https://www.derstandard.de/rss title: Der Standard web: https://www.derstandard.de - - url: https://newsfeed.zeit.de/ + - url: https://newsfeed.zeit.de/index title: Zeit Online web: https://zeit.de - url: https://www.faz.net/rss/aktuell diff --git a/run.sh b/run.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash + +perlanet config.yaml +sed -e "s/<!--UPDATED-->/$(date +%c)/" -i index.html diff --git a/template.html b/template.html @@ -55,12 +55,15 @@ <main class="main"> <h1>[% feed.title | html %]</h1> - <p style="margin-bottom:5em;">[% feed.description | html %]</p> + <p>[% feed.description | html %]</p> + + <!-- This is updated by find-and-replace --> + <p style="margin-bottom:2em;"><!--UPDATED--></p> [% FOREACH entry IN feed.entries %] <article class='post-entry'> <h2><a href="[% entry.link | url | html %]" class="hyperlink">[% entry.title | html %]</a></h2> - <p style="margin-top:2em;"> + <p style="margin-top:1em;"> [% IF entry.summary.body %] [% entry.summary.body %] [% ELSE %] @@ -68,11 +71,10 @@ [% END %] </p> [% IF entry.author OR entry.issued %] - <strong style="margin-top:2em;"> + <p style="margin-top:1em;"> Published - [% IF entry.author %] by [% entry.author | html; END %] - [% IF entry.issued %] on [% entry.issued | html; END %] - </strong> + [% IF entry.issued %] on <strong>[% entry.issued | html %]</strong>[% END %] + </p> [% END %] </article> [% END %]