HangfireIO / Cronos

A fully-featured .NET library for working with Cron expressions. Built with time zones in mind and intuitively handles daylight saving time transitions
MIT License
974 stars 114 forks source link

Shouldn't 0 0 15,L * ? work? #52

Open kampilan opened 1 year ago

kampilan commented 1 year ago

0 0 15,L * ? should produce the 15th of the month or the Last day of the month. Instead it complains about the L not being a number.

Am I missing something or should this be supported?

Thanks Jim

arical commented 1 year ago

I came here to post the exact same question. A common pattern for invoices is to run twice per month. On the 15th and the last day.

This library has been amazing so far, but this is making us scramble to find a work around. I was hoping that using 15,31 would work, but it doesn't work for months with less than 31 days.

kampilan commented 1 year ago

Exactly what I needed it for 15,L invoicing. I hate doing this but NCrontab-Advanced supports this and is less quirky. I was able to swap it out in just a few minutes. Good luck

arical commented 1 year ago

Thanks @kampilan. Good to know! Ideally we'd like to continue using Cronos though as the library itself has great support for timezones, which we are making heavy use of.

odinserj commented 1 year ago

Yeah, sounds as a great addition. Need to change the grammar first and then make the according changes to the code, it will be much easier (than changing the grammar). Will try to implement this in the near future, but any help with the grammar is highly appreciated!

arical commented 10 months ago

We have customers that would still love this functionality. It's the only bit of functionality we'd still really love to see. Anything we can do to help out? I had a quick look at the grammar code but that's definitely not my forte 😅

binojvijayakumar commented 9 months ago

any updates on this request?

anvaravind commented 6 months ago

+1 waiting for this feature