#!/usr/bin/env sh database="db/games.rec" ## BEGIN: TEMPLATES ## gameheadertmpl='

{{Module}} ({{System}}) #

{{Module}} is a game of {{System}} that I started playing on {{Started}} as a {{Role}}. It is a {{Format}} {{Length}} and is currently {{Status}}.

Here is how it went!

' updatetmpl='

{{Created}} #

{{Text}} ' gamefootertmpl='
🎲🎲
' toctmpl='
  • {{Module}} ({{System}})
  • ' ## END: TEMPLATES ## exec > dist/index.html ## BEGIN: STYLE ## cat< EOF ## END: STYLE ## ## BEGIN: INTRO ## cat<Gamelogs

    All the roleplaying games I've played.

  • src: https://git.tilde.town/dozens/gamelog
  • dozens webring: previous index next
  • rss
  • EOF ## END: INTRO ## ## BEGIN: TOC ## echo '

    Contents

    ' recsel $database -t Game | recfmt "$toctmpl" ## END: TOC ## ## BEGIN: BODY ## allgames=(`recsel $database -t Game -P Id -C | tr '\n' ' '`) for idx in "${allgames[@]}" do recsel $database -t Game -e "Id = $idx" | recfmt "$gameheadertmpl" recsel $database -t Update -e "Game = $idx" | recfmt "$updatetmpl" | markdown echo $gamefootertmpl done ## END: BODY ##