diff --git a/build.sh b/build.sh index 564fecd..9db6d06 100755 --- a/build.sh +++ b/build.sh @@ -58,8 +58,10 @@ convert_to_array() { } add_date_to_array() { - meta_array["date"]="$(date -r $1 +'%b %d, %Y')" - + if test -z "${meta_array[date]}"; then # If there is no existing date in the metadata + meta_array["date"]="$(date -r $1 +'%b %d, %Y')" + fi + echo "${meta_array[date]}" } add_header_and_footer() {