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
1.01k
stars
120
forks
source link
Minor request: Public variables for Hourly / Daily / Minutely #64
A small request that might be easily satisfied - can the static readonly values on CronExpression.cs become public rather than private?
I noticed in my code that a common usage pattern was this:
var scheduledTime = _configuration["AlertsScheduledJobsWorker:ScheduledTimeExpression"]
?? "0 * * * *"; // By default run once per hour
I noticed this happens a half dozen times in our codebase, so I decided to replace 0 * * * * with a constant CronExpression.Hourly, and I decided to check if your library had one. It looks like those values already exist, but they are marked private. Would you accept a small PR to make these values public?
A small request that might be easily satisfied - can the static readonly values on
CronExpression.cs
become public rather than private?I noticed in my code that a common usage pattern was this:
I noticed this happens a half dozen times in our codebase, so I decided to replace
0 * * * *
with a constantCronExpression.Hourly
, and I decided to check if your library had one. It looks like those values already exist, but they are marked private. Would you accept a small PR to make these values public?