This commit is contained in:
David Eisinger
2025-02-16 02:38:31 -05:00
parent 42f4bc63ad
commit 364f39a761

View File

@@ -3,10 +3,12 @@
{{ $content = $content | replaceRE `<!--more-->\n+` "" -}}
{{ $content = $content | replaceRE `\[([^\]]+)\]\[(\d+)\]` "$1[$2]" -}}
{{ $content = $content | replaceRE `(?m)^\[(\d+)\]: (.*)$` "=> $2 [$1] $2" -}}
{{ $content = $content | replaceRE `=> (/.+\.pdf)` (printf "=> %s$1" site.BaseURL) -}}
{{ $content = $content | replaceRE `(?m) >` ">" -}}
{{ $content = $content | replaceRE `\[([^\]]+)\]\([^\)]+\)` "$1" -}}
{{ $content = $content | replaceRE `(?m)^ >` ">" -}}
{{ $content = $content | replaceRE `(?m)^ \*` "* ⇢" -}}
{{ $content = $content | replaceRE `(?m)^- ` "* " -}}
{{ $content = $content | replaceRE `(?m)^[\*-]{3}$` "✱ ✱ ✱" -}}
{{ $content = $content | replaceRE `=> (/.+\.pdf)` (printf "=> %s$1" site.BaseURL) -}}
{{ $audioRE := `<audio controls src="(.*/([^"]+))"></audio>` -}}
{{ range findRE $audioRE $content -}}
{{ $url := . | replaceRE $audioRE "$1" | replaceRE ` ` "%20" -}}