cron = CrontabParser.new(`crontab -l`)
now = Time.now
cron.find_all{|row|
row.should_run?(now)
}.each{|row|
puts "#{row.cmd} goes run just now"
}
cron = CrontabParser.new(<<-CRON)
* * * * * monitor-process
@daily mailme
@monthly full-backup
CRON
now = Time.now
cron.find_all{|row|
row.should_run?(now)
}.each{|row|
puts "#{row.cmd} goes run just now"
}
-
Notifications
You must be signed in to change notification settings - Fork 5
License
uu59/crontab-parser
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
License
Stars
Watchers
Forks
Packages 0
No packages published