From 60a0feb39d3ec975472f12377db9182789776c10 Mon Sep 17 00:00:00 2001 From: Serghei Iakovlev Date: Mon, 16 May 2022 02:13:01 +0200 Subject: Simplified setting the author --- layouts/index.humanstxt.txt | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) (limited to 'layouts/index.humanstxt.txt') diff --git a/layouts/index.humanstxt.txt b/layouts/index.humanstxt.txt index 0b25434..93e794b 100644 --- a/layouts/index.humanstxt.txt +++ b/layouts/index.humanstxt.txt @@ -1,20 +1,10 @@ -CONGRATULATIONS, you found my humans.txt file! - -─────────────────────────────────────────────────────────────────────────────── - -{{ with site.Author }} - {{- $author_type := (printf "%T" site.Author) }} - {{- if (or (eq $author_type "map[string]string") (eq $author_type "map[string]interface {}")) }} +{{- with site.Author.name }} /* TEAM */ - {{ range $i, $member := site.Author }} - {{- if (eq (printf "%T" $member) "maps.Params") }} - {{- partial "team-member.html" (dict "context" . "member" $member) -}} - {{- else if (eq (printf "%T" $member) "string") }} - {{- partial "team-member.html" (dict "context" . "member" site.Author) -}} - {{- break -}} - {{- end }} - {{- end }} - {{- end }} + + Author: {{ . }} +{{ with site.Author.email }} Contact: {{ . }}{{ end }} +{{ with site.Author.github }} GitHub: {{ . }}{{ end }} +{{ with site.Author.location }} From: {{ . }}{{ end }} {{- end }} /* SITE */ -- cgit v1.2.3