diff options
Diffstat (limited to 'bin/func')
-rw-r--r-- | bin/func | 21 |
1 files changed, 16 insertions, 5 deletions
@@ -9,9 +9,16 @@ tmp_file="${tmp_dir}/tmp" rss_dir="${src_dir}/b" rss_out_file="${out_dir}/rss.xml" -website_title="rgoncalves.se" -website_link="https://${website_title}" -website_description="hacker and " +website_domain="rgoncalves.se" +website_title="${website_domain}" +website_link="https://${website_domain}" +website_email="contact@${website_domain}" +website_generator="${website_domain}'s ssg" +website_description="devops and hacker D:" +website_language="en" + +date_default_hour="17:00:00" +date_default_timezone="+0200" __get_value() { # 1: filename @@ -59,8 +66,12 @@ __get_value_date_human() { __get_value_date_publication() { # 1: filename # Get publication date according to rfc 2822 and return a safe string. - __get_value_date "${1}" | - xargs date -j -f "%Y-%m-%d" +"%a, %d %b %Y %H:%M:%S %z" + local _date + + _date="$(__get_value_date ${1})" + _date="${_date} ${date_default_hour} ${date_default_timezone}" + + date -j -f "%Y-%m-%d %H:%M:%S %z" +"%a, %d %b %Y %H:%M:%S %z" "${_date}" } __get_out_filename() { |