chronic_cron 0.2.27 → 0.2.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/lib/chronic_cron.rb +4 -4
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 18ca6b9986162d123d81aaa8dbe1da0dd7d0eb5f
|
4
|
+
data.tar.gz: a0dfb41b5ce09016b721dc86240dc179b2620fcb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 793e7397772cafeee53ace1978cae1eeb3b315247fa14b4d8291fb3b398648c6148a65b8b4579985a351fa18dbea5455fc46516d8b8a89e9e368e5c29fd94279
|
7
|
+
data.tar.gz: 809a78a5b889d2506bc897133d7dc66d17441dada9dbaed57d14e76a176630468fe011d866984a3ab5176afdda5a976b42216b96ffebb28ef7673c0d9ba0ae69
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/lib/chronic_cron.rb
CHANGED
@@ -81,20 +81,20 @@ class ChronicCron
|
|
81
81
|
end
|
82
82
|
|
83
83
|
# e.g. 10:15am every day
|
84
|
-
get /(\d{1,2})
|
84
|
+
get /(\d{1,2}):?(\d{1,2})([ap]m)?\s+#{daily}/ do |raw_hrs, mins, meridiem|
|
85
85
|
hrs = in24hrs(raw_hrs, meridiem)
|
86
86
|
"%s %s * * *" % [mins.to_i, hrs]
|
87
87
|
end
|
88
88
|
|
89
89
|
# e.g. at 7:30am Monday to Friday
|
90
|
-
get /(\d{1,2})
|
90
|
+
get /(\d{1,2}):?(\d{1,2})([ap]m)?\s+(\w+) to (\w+)/ do
|
91
91
|
|raw_hrs, mins, meridiem, wday1, wday2|
|
92
92
|
hrs = in24hrs(raw_hrs, meridiem)
|
93
93
|
"%s %s * * %s-%s" % [mins.to_i, hrs , wday1, wday2]
|
94
94
|
end
|
95
95
|
|
96
96
|
# e.g. at 11:00 and 16:00 on every day
|
97
|
-
get /(\d{1,2})
|
97
|
+
get /(\d{1,2}):?(\d{1,2}) and (\d{1,2}):?\d{1,2} (?:on )?#{daily}/ do
|
98
98
|
"%s %s,%s * * *" % params[:captures].values_at(1,0,2)
|
99
99
|
end
|
100
100
|
|
@@ -110,7 +110,7 @@ class ChronicCron
|
|
110
110
|
weekday = '((?:mon|tue|wed|thu|fri|sat|sun)\w*)'
|
111
111
|
|
112
112
|
# e.g. at 10:30pm on every Monday
|
113
|
-
get /(\d{1,2})
|
113
|
+
get /(\d{1,2}):?(\d{1,2})([ap]m)?\s+(?:on )?every #{weekday}/i do
|
114
114
|
|raw_hrs, mins, meridiem, wday|
|
115
115
|
hrs = in24hrs(raw_hrs, meridiem)
|
116
116
|
"%s %s * * %s" % [mins, hrs , wday]
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chronic_cron
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.28
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -29,7 +29,7 @@ cert_chain:
|
|
29
29
|
aYYwh4InyS/QZr4LG0nh0TuYVP5vwm1cCSlLlo4dlv7bl7Q4y815j70z8O4oUrT8
|
30
30
|
5oSIzmlVDEDmwAibYqdf+aHqmum1mkYW
|
31
31
|
-----END CERTIFICATE-----
|
32
|
-
date: 2014-01-
|
32
|
+
date: 2014-01-11 00:00:00.000000000 Z
|
33
33
|
dependencies:
|
34
34
|
- !ruby/object:Gem::Dependency
|
35
35
|
name: app-routes
|
metadata.gz.sig
CHANGED
Binary file
|