diff options
author | Romain Gonçalves <me@rgoncalves.se> | 2022-11-16 22:54:11 +0100 |
---|---|---|
committer | Romain Gonçalves <me@rgoncalves.se> | 2022-11-16 22:54:11 +0100 |
commit | f416a38df0caf397d22a07f227f1de72856a100a (patch) | |
tree | 5161e0f2b4a8f3533743dd934b072c6c38061403 /bin/rssg | |
parent | 61a336b23cfba498f56595f452a3b3440af28e88 (diff) | |
download | rgoncalves.se-f416a38df0caf397d22a07f227f1de72856a100a.tar.gz |
feat(bin): generate + embed description in RSS articles
Diffstat (limited to 'bin/rssg')
-rwxr-xr-x | bin/rssg | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -27,11 +27,12 @@ EOF for file in $(__list_files_date "${rss_dir}"); do title=$(__get_value_title "${file}") date=$(__get_value_date_publication "${file}") - link="${website_link}/$(__get_final_filename ${file})" + link="${website_link}/$(__get_final_filename "${file}")" + description=$(__generate_rss_body "${file}") if [ "${uname}" = "Linux" ]; then - guid="$(echo ${link} | sha256sum | cut -d ' ' -f 1)" + guid="$(echo "${link}" | sha256sum | cut -d ' ' -f 1)" else - guid="$(echo ${link} | sha256)" + guid="$(echo "${link}" | sha256)" fi cat <<-EOF >> "${rss_out_file}" @@ -40,6 +41,7 @@ for file in $(__list_files_date "${rss_dir}"); do <link>${link}</link> <pubDate>${date}</pubDate> <guid>${guid}</guid> + <description>${description}</description> </item> EOF done |