diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 8464276..1d7a284 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -27,6 +27,7 @@ disqusShortname = "yourdiscussshortname" hideCredits = false hideCopyright = false + since = 2019 # Git Commit in Footer, uncomment the line below to enable it. commit = "https://github.com/luizdepra/hugo-coder/tree/" diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index a5f42df..1677656 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -3,7 +3,14 @@ {{ with .Site.Params.footercontent | safeHTML }}

{{.}}

{{ end }} - {{ if not .Site.Params.hideCopyright }} © {{ now.Format "2006" }}{{ end }} + {{ if not .Site.Params.hideCopyright }} + {{ with .Site.Params.since }} + © {{ if lt . now.Year }}{{ . }} - {{ end }}{{ now.Year }} + {{ else }} + © {{ now.Year }} + {{ end }} + {{ if .Site.Params.Author }} {{ .Site.Params.Author }} {{ end }} + {{ end }} {{ if not .Site.Params.hideCredits }} {{ if not .Site.Params.hideCopyright }} · {{ end }} {{ i18n "powered_by" }} Hugo & Coder.