I'm currently writing #Fennel examples, and this is delightful. I even managed to make the decide
function even more beautiful than it was!
(local ruleset [is-in-ai-robots-txt?
default])
(fn decide [request]
(accumulate [outcome nil
_ f (ipairs ruleset)
&until (not= outcome nil)]
(f request)))
This is perfection.
From nothing to running iocaine + Caddy with ai.robots.txt
's robots.json
and a few metrics as a starting point.
Contains #Roto, #Lua, and #Fennel - and a few tests too, for each.