Thanks, @sean_sullivan . Lots to digest here. Alas, I can only give it one .
I was hoping the new galaxy had something like github provides, where you can throw a block of markdown at its API and it throws back the rendered html. Here’s a bash function that uses it:
gfm2html ()
{ # github-flavored markdown to html. Requires jq.
local fname=${1-README.md}
if [ ! -f "$fname" ]; then
echo "'$fname' not found." 1>&2
else
jq --slurp --raw-input '{"text": "\(.)", "mode": "markdown"}' < "$fname" \
| curl --data @- https://api.github.com/markdown
fi
}