{{- $text := .Get 0 -}} {{- $unreleased := strings.HasSuffix $text "-unreleased" -}} {{- if $unreleased -}} {{- $tag := strings.TrimSuffix "-unreleased" $text -}} {{- $content := printf "Since %s (unreleased)" $tag -}} {{- partial "shortcodes/badge.html" (dict "content" $content "color" "indigo" "class" "" "border" true "icon" "beaker" ) -}}{{- /* no empty line */ -}} {{- else -}} {{- $tag := $text -}} {{- $link := printf "/blog/goreleaser-%s" $tag -}} {{- $content := printf "Since %s" $tag -}} {{- partial "shortcodes/badge.html" (dict "content" $content "color" "indigo" "class" "" "border" true "icon" "status-online" ) -}} {{- /* no empty line */ -}} {{- end -}}