get the title from the html document instead because that's saver

This commit is contained in:
Lucy 2020-07-17 00:38:30 +02:00
parent cddfffbbe8
commit e0ed767c63

View File

@ -63,7 +63,7 @@ create_entry() {
# convert new markdown posts to html
pandoc -s --css=/css/sakura-vader.css "$path" src/footer/footer.md -t html5 -f markdown -o "dist/$outpath"
# then add it to the index
title="$(grep -h '^title: ' "$path" | sed 's/title: //g')"
title=$(grep -h '<title>' "dist/$outpath" | sed 's/<title>//g;s/<\/title>//g')
created=$(grep -h '^date: ' "$path" | sed 's/date: //g')
html_entry "$outpath" "$created" "$title"
rss_entry "$title" "dist/$outpath"