summaryrefslogtreecommitdiff
path: root/layouts/_default/single.gmi
blob: 6ac4358cc9e17780abc90cd6f55f2554aec38243f8f52a01ab3861abe71e8930 (plain)
1
2
3
4
5
6
7
8
9
{{ define "main" }}
=> ./{{ replaceRE ".+?/" "../" .RelPermalink | safeURL }} Return to homepage

{{ $content := .RawContent }}
{{- $content = $content | replaceRE `\[(.+?)\]\((.+?)\)` "=> $2 $1" }}
{{- $content = $content | replaceRE `\*{3}(.+?)\*{3}|\*{2}(.+?)\*{2}|\*{1}(.+?)\*{1}` "$1$2$3$4$5$6" }}
{{- $content = $content | replaceRE `\n- (.+?)` "\n* $1" }}
{{- $content = $content | replaceRE `<br/?>` "\n" }}
{{- $content | safeHTML }}{{ end }}