night0721.xyz/layouts/shortcodes/repolist.html

13 lines
309 B
HTML
Raw Normal View History

2024-03-14 02:11:51 +01:00
<ul>
{{ $files := readDir "content/repos" }}
{{ range $files }}
{{ $fileNameParts := split .Name "." }}
{{ $fileName := index $fileNameParts 0 }}
{{ if ne $fileName "_index" }}
<li>
<a href="/repos/{{ $fileName }}">{{ $fileName }}</a>
</li>
{{ end }}
{{ end }}
</ul>