Music listing page
This commit is contained in:
8
themes/v2/layouts/music/list.gmi
Normal file
8
themes/v2/layouts/music/list.gmi
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# {{ .Title }}
|
||||||
|
|
||||||
|
{{ range where .Site.RegularPages "Params.exclude_music" "!=" true -}}
|
||||||
|
{{ range sort (.Resources.Match "*.mp3") "Title" "desc" -}}
|
||||||
|
=> {{ .RelPermalink }} {{ substr .Title 0 -4 }}
|
||||||
|
{{ end -}}
|
||||||
|
{{ end -}}
|
||||||
|
|
||||||
@@ -11,7 +11,7 @@
|
|||||||
{{ range findRE $audioRE $content -}}
|
{{ range findRE $audioRE $content -}}
|
||||||
{{ $url := . | replaceRE $audioRE "$1" | replaceRE ` ` "%20" -}}
|
{{ $url := . | replaceRE $audioRE "$1" | replaceRE ` ` "%20" -}}
|
||||||
{{ $title := . | replaceRE $audioRE "$2" -}}
|
{{ $title := . | replaceRE $audioRE "$2" -}}
|
||||||
{{ $content = replace $content . (printf "=> %s %s" $url $title) -}}
|
{{ $content = replace $content . (printf "=> %s %s" $url (substr $title 0 -4)) -}}
|
||||||
{{ end -}}
|
{{ end -}}
|
||||||
{{ range findRE `{{<(dither|thumbnail) [^/]+/>}}` $content -}}
|
{{ range findRE `{{<(dither|thumbnail) [^/]+/>}}` $content -}}
|
||||||
{{ $rendered := $page.RenderString . -}}
|
{{ $rendered := $page.RenderString . -}}
|
||||||
|
|||||||
Reference in New Issue
Block a user