MichaelXavier / cron

Cron data structure and parser for Haskell
Other
53 stars 33 forks source link

Exposing System.Cron.Schedule.forkJob #43

Closed igrep closed 10 months ago

igrep commented 4 years ago

I know this package is just "data structure and parser" by definition, but found the scheduling feature is useful. So I want to reuse it for one of my applications which parses the schedule specification in a different format. In such a use case, addJob, runSchedule, etc are unnecessary: calling forkJob directly with Jobs parsed by the application is sufficient and more efficient. Can you expose System.Cron.Schedule.forkJob?

MichaelXavier commented 4 years ago

That seems reasonable. I'm swamped, so I'll accept an MR if you want to go ahead and expose that.

mauke commented 1 year ago

I could really use this function, too.

I'd like to be able to write an alternative to execSchedule that doesn't just print errors to stdout and keep running. To do that, I need to be able to call forkJob.

igrep commented 10 months ago

Looks fixed by https://github.com/MichaelXavier/cron/commit/d9193309bd06b04607898212f9c477af4894c021