Feature request: combining multiple RRULEs

Open
#3 6 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
ruby
Domain
backend

Research direction

The issue names no files, tests, or entry points. Start by locating the library's RRULE parsing and expansion API, then examine how enumerators are built; done means multiple RRULE properties can be combined while yielding distinct timestamps, with coverage for the payroll example.

Written by the indexing model from the issue text.

Description

Many calendar implementations support multiple RRULE properties. This is so that repetition rules that aren't possible to specify with one RRULE can be applied to an event.

For example, consider "Payroll is due twice a month, on the last weekday on or before the 15th and on the last weekday of the month".

A set of RRULE properties would look like this:

RRULE:FREQ=MONTHLY;BYDAY=MO,TU,WE,TH,FR;BYMONTHDAY=13,14,15;BYSETPOS=-1
RRULE:FREQ=MONTHLY;BYDAY=MO,TU,WE,TH,FR;BYSETPOS=-1

It would be awesome if the library supported combining multiple RRULE properties and returning a enumerator with the distinct timestamps generated by them. (One way to do this could be through operators that can add and subtract.)

Dominant language
Ruby
Stars
186
Forks
26
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from square/ruby-rrule

All issues in square/ruby-rrule

Similar issues

More Ruby issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.