Skip to content

Commit

Permalink
State that #next #prev #within are >= 1.10, gh-94
Browse files Browse the repository at this point in the history
  • Loading branch information
jmettraux committed Mar 7, 2024
1 parent 748ad56 commit ca79526
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ c = Fugit.parse_cron('0 12 * * mon#2')

# `#next` and `#prev` return Enumerable instances
#
# These two methods are available since fugit 1.10.0.
#
c.next(Time.parse('2024-02-16 12:00:00'))
.take(3)
.map(&:to_s)
Expand All @@ -157,6 +159,8 @@ c.prev(Time.parse('2024-02-16 12:00:00'))
# instances that correspond to the occurrences of the cron within
# the time range
#
# This method is available since fugit 1.10.0.
#
c.within(Time.parse('2024-02-16 12:00')..Time.parse('2024-08-01 12:00'))
.map(&:to_s)
# => [ '2024-03-11 12:00:00',
Expand Down

0 comments on commit ca79526

Please sign in to comment.