Am using Ice Cube gem https://github.com/seejohnrun/ice_cube to schedule events, I want to make every event to appear in the app every week on monday, and after 6 hours the event title should be marked with a red color.
In the doc ice cube has this example for setting a duration
# or give the schedule a duration and ask if occurring_at?
schedule = IceCube::Schedule.new(now, :duration => 3600)
schedule.add_recurrence_rule IceCube::Rule.daily
schedule.occurring_at?(now + 1800) # true
which I translated to my need as the following :
start_date = Time.now.utc - 10.days # any datetime basically
schedule = IceCube::Schedule.new(start_date, :duration => (6.hours).seconds)
schedule.add_recurrence_rule IceCube::Rule.weekly(1).day(:monday)
But from what I get it seems that the 6 hours duration works only for the FIRST occurrence (6 hours from the start_date), what I want is 6 hours from every monday, every week.