fugit 1.4.4 → 1.4.5
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of fugit might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/CREDITS.md +2 -1
- data/README.md +14 -0
- data/lib/fugit.rb +1 -1
- data/lib/fugit/cron.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e49e2002591b450a853f0a27eb942fd69f69a59d6803c229bcdb51af471b6862
|
4
|
+
data.tar.gz: f9f6921007e4e0df0908e63f080d0f710ba60401299440347ecc994b6ccf56fc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 22dc41bcc969d3505157572bbe899d7f160f8ab06ce42b3f4b494911ae69d96bde4be7422f55fd31c33491899b3af4ec50b4870f419145d103bd230d94affecd
|
7
|
+
data.tar.gz: 50d62627a4ed4fe54cf31d2901eebdd56f57a69f0464f0ede436184af604d1d18622e3159b487f9a92a35cfbf8a3ed65b58887dc3f43514e86a73e4db5d11692
|
data/CHANGELOG.md
CHANGED
data/CREDITS.md
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
|
2
2
|
# fugit credits
|
3
3
|
|
4
|
+
* Karen Sawrey https://github.com/karensawrey gh-47, Mon%2+1 rework idea
|
4
5
|
* Olle Jonsson https://github.com/olleolleolle gha Ruby 3.0
|
5
6
|
* Andy Pfister https://github.com/andyundso gh-53, entering DST
|
6
7
|
* Solteszad https://github.com/solteszad gh-51, fix previous_time vs last day of month
|
@@ -11,7 +12,7 @@
|
|
11
12
|
* Danny Ben Shitrit https://github.com/DannyBen nat variants, gh-38
|
12
13
|
* Dominik Sander https://github.com/dsander #rough_frequency 0, gh-36
|
13
14
|
* Milovan Zogovic https://github.com/assembler Cron#match? vs TZ, gh-31
|
14
|
-
* Jessica Stokes https://github.com/ticky 0-24 issue with cron, gh-30
|
15
|
+
* Jessica Stokes https://github.com/ticky 0-24 issue with cron, gh-30 and gh-47
|
15
16
|
* Shai Coleman https://github.com/shaicoleman parse_nat enhancements, gh-24, gh-25, gh-28, and gh-37
|
16
17
|
* Jan Stevens https://github.com/JanStevens Fugit.parse('every 15 minutes') gh-22
|
17
18
|
* Fabio Pitino https://github.com/hspazio nil on February 30 gh-21
|
data/README.md
CHANGED
@@ -203,8 +203,22 @@ p EtOrbi.parse('2019-01-01').rweek % 2 # => 1
|
|
203
203
|
p EtOrbi.parse('2019-04-11').wday # => 4
|
204
204
|
p EtOrbi.parse('2019-04-11').rweek # => 15
|
205
205
|
p EtOrbi.parse('2019-04-11').rweek % 2 # => 1
|
206
|
+
|
207
|
+
c = Fugit.parse('* * * * tue%2')
|
208
|
+
c.match?('2019-01-01') # => false, since rweek % 2 == 1
|
209
|
+
c.match?('2019-01-08') # => true, since rweek % 2 == 0
|
210
|
+
|
211
|
+
c = Fugit.parse('* * * * tue%2+1')
|
212
|
+
c.match?('2019-01-01') # => true, since (rweek + 1) % 2 == 0
|
213
|
+
c.match?('2019-01-08') # => false, since (rweek + 1) % 2 == 1
|
214
|
+
|
215
|
+
# ...
|
206
216
|
```
|
207
217
|
|
218
|
+
`sun%2` matches if Sunday and `current_date.rweek % 2 == 0`
|
219
|
+
`tue%3+2` matches if Tuesday and `current_date.rweek + 2 % 3 == 0`
|
220
|
+
`tue%x+y` matches if Tuesday and `current_date.rweek + y % x == 0`
|
221
|
+
|
208
222
|
|
209
223
|
## `Fugit::Duration`
|
210
224
|
|
data/lib/fugit.rb
CHANGED
data/lib/fugit/cron.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fugit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Mettraux
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-04-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: raabro
|