Hacker News new | ask | show | jobs
by turtleyacht 1333 days ago
systemd just released a new version, according to HN [1]. What if we published a uniform interface to a smattering of different scripts, as scripts?

It would be like asdf for daemons.

For cron, we could mark a `cal` output with a pattern, and it would emit the necessary cron:

    January 2022   February 2022
     1 2 3 4 5 ...  1 2 3 ...

    > 1/1 1/2 1/3 1/4
    Pattern matching... Done.
    Oh, you'd like to run it (d)aily or (w)eekly?
    > w
    The cron pattern for that would be:
      0 0 * * 0
    (C)opy to clipboard, (q)uit, (m)ore?
    > C
    Copied. Exiting.
It would let us investigate sequences (or skipped sequences) as certain colored vertices in a graph. Or something like that, maybe.

And submit a patch to each init daemon to add similar capabilities.

[1] https://news.ycombinator.com/item?id=33416599