Ancestors

Written by modulux on 2024-12-30 at 10:23

Today on "Unix is a coherent, orthogonal system," my cron job refused to run because it has unescaped % signs, which as we all know are totally a thing in any other shell context... oh wait, no they're not.

But for some reason if you put a % sign on a cron job, it assumes you wanted to do a line break, because... well, it's just logical, it's Unix.

(I rarely complain about Unix quirks but this one is weird as hell.)

=> More informations about this toot | More toots from modulux@node.isonomia.net

Toot

Written by ben on 2024-12-30 at 10:34

@modulux This one always trips me up. It hardly ever matters, which means that when it does matter I’ve forgotten about it again. (Usually in date format strings, or printf etc.)

=> More informations about this toot | More toots from benjamineskola@hachyderm.io

Descendants

Written by modulux on 2024-12-30 at 10:34

@benjamineskola Yes, I was piping to ts to get timestamps on the log, and of course I used a format string, and of course I did not escape it because... why is this even a thing?

=> More informations about this toot | More toots from modulux@node.isonomia.net

Written by ben on 2024-12-30 at 10:53

@modulux well, I suppose it’s necessary to have a way to include newlines in a cron job, which are otherwise slightly constrained shell scripts.

But I’m not sure if there would have been a better choice than %. \n is the obvious choice but maybe it has too high a chance of conflicting with an actual use of \n, whereas % is relatively rarely used? That’s just guessing though.

=> More informations about this toot | More toots from benjamineskola@hachyderm.io

Proxy Information
Original URL
gemini://mastogem.picasoft.net/thread/113741322212406375
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
278.892962 milliseconds
Gemini-to-HTML Time
1.552258 milliseconds

This content has been proxied by September (3851b).