diff options
Diffstat (limited to 'bin/ssg-template')
-rw-r--r-- | bin/ssg-template | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/bin/ssg-template b/bin/ssg-template index d246028..e0689cb 100644 --- a/bin/ssg-template +++ b/bin/ssg-template @@ -138,12 +138,12 @@ _render_index() { title=$(_get_value "${file}" "title" "$(_get_title ${file})") - cat <<-EOF - <li> - <a href="${path}">${title}</a> - <span>$(_get_date_human "${file}")</span> - </li> - EOF + echo "<li>" + if [ $(_get_value "${file}" "index_show_date") ]; then + echo "<span>$(_get_date_human \"${file}\")</span>" + fi + echo "<a href=\"${path}\">${title}</a>" + echo "</li>" done echo "</ul>" } |