Add a best_game shortcode

This commit is contained in:
Eryn Wells 2022-04-24 17:27:13 -07:00
parent 8fb0e09e1b
commit 777a10c734
4 changed files with 41 additions and 9 deletions

View file

@ -0,0 +1,8 @@
{{ $nethack_data := $.Site.Data.nethack.logfile }}
{{ $logfile := slice }}
{{ range $nethack_data }}
{{ $logfile = $logfile | append .logfile }}
{{ end }}
<div class="logentry">
{{ partial "nethack/logentry.html" (index (sort $logfile "score" "desc") 0) }}
</div>