On 16/12/2024 22:18, Pablo Rodriguez via ntg-context wrote:
It seems that it is too complex for me (and I have already invested two afternoons in this).
For some reason, not meant to be in my case,
like everyday for one year 8<--- \startluacode function userdata.now(dd) local wdays = {"Sun ", "Mon ", "Tue ", "Wed ", "Thu ", "Fri ", "Sat "} local z = os.date("*t", os.time()) local nn = os.date("*t", os.time{year=z.year, month=z.month, day=z.day+dd}) --context(wdays[nn.wday] .. nn.year .. "-" .. nn.month .. "-" .. nn.day) context(string.format("%s %04d-%02d-%02d ", wdays[nn.wday], nn.year, nn.month, nn.day)) end \stopluacode \starttext \tt Today is \ctxlua{userdata.now(0)} \dorecurse{366}{\ctxlua{userdata.now(\recurselevel)}\\ } \stoptext --->8 ( i'm not fluent in lua, so there might be a much better way to handle it ;-)