From dc325ab967af67851a6abc5f13aabf69c2850033 Mon Sep 17 00:00:00 2001 From: Cem Keylan Date: Mon, 13 Apr 2020 01:01:10 +0300 Subject: update --- build | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'build') diff --git a/build b/build index 4befe7d..bf2e458 100755 --- a/build +++ b/build @@ -90,11 +90,16 @@ EOF site_index() { cp index/index.md src/index.md - find index -name '*.news' | sort -r | while read -r news ; do + find index -name '*.news' | sort -r | sed 3q | while read -r news ; do newsdate="${news##*/}" ; newsdate="${newsdate%.news}" - printf '\n### %s\n\n' "$(date --date="$newsdate" +%b\ %d\ %Y)" >> src/index.md + printf '\n%s\n-----------\n\n' "$(date --date="$newsdate" +%b\ %d\ %Y)" >> src/index.md cat "$news" >> src/index.md done + find index -name '*.news' | sort -r | while read -r news ; do + newsdate="${news##*/}" ; newsdate="${newsdate%.news}" + printf '\n%s\n-----------\n\n' "$(date --date="$newsdate" +%b\ %d\ %Y)" >> src/news.md + cat "$news" >> src/news.md + done } genrss() { -- cgit v1.2.3