commit db31780c91709e47c09f95042187d81f3b4fc028 parent 88bd77fd09c214bbddc2d10e9946fa99b9af7e75 Author: Nuno Sempere <nuno.semperelh@protonmail.com> Date: Thu, 13 Jul 2023 21:46:32 +0000 add read more pointer. Diffstat:
| M | apps/blagh/app.rc | | | 9 | +++++++-- |
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/apps/blagh/app.rc b/apps/blagh/app.rc @@ -91,11 +91,16 @@ fn blagh_body { # XXX Not sure why this fixes issues with blog setup, probably bug in fltr_cache! for(p in `{get_post_list $blagh_root^$blagh_dirs}) { l=`{echo -n $p|sed 's!'$sitedir^'/?(.*)([0-9][0-9][0-9][0-9]/[0-9][0-9]/[0-9][0-9])(/[^/]+/)!\2 /\1\2\3!'} - sed '1s!.*^') ('^$l(1)^')!' < $p/index.md + sed '1s!.*^') ('^$l(1)^')!' < $p/index.md | head -n 10 + echo + echo '<p style="text-align: left; margin-right: 10%; font-size: 28px;"><a style="text-decoration: none;" href="'^$l(2)^'"><b>→ Ꙭ</b> ...</a></p>' + # ⇒ + # ➡ + # https://www.smashingmagazine.com/2009/07/designing-read-more-and-continue-reading-links/ # cat $p/index.md | sed '1s!.*^') ('^$l(1)^')!' | sed -n '/^.\{15\}/p' | echo echo # Needed extra \n so markdown doesn't mess up the formatting, probably can be done in sed. echo # - } | head -n 9 | $formatter | sed 's/h[2-9]/i/g'| sed 's/h1/h3/g' + } | head -n 12 | $formatter | sed 's/h[2-9]/i/g'| sed 's/h1/h3/g' # HTML posts for(p in `{get_post_list $blagh_root^$blagh_dirs}) { cat < $p/index.html