Skip to content

Instantly share code, notes, and snippets.

@perezd
Created February 27, 2009 08:04
Show Gist options
  • Save perezd/71349 to your computer and use it in GitHub Desktop.
Save perezd/71349 to your computer and use it in GitHub Desktop.
require 'smart_month'
SmartMonth::Rulesets.add_rule('Christmas','December 25th')
Month.december.christmas #=> Date object containing December 25th of this year.
SmartMonth::Rulesets.add_rule('Weekly Meetings','every friday')
Month.march.weekly_meetings #=> array of corresponding Date objects.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment