Class: Git::Heatmap::Monthly
Instance Method Summary collapse
Methods inherited from Period
Instance Method Details
#key(t, p = 0) ⇒ Object
102 103 104 105 106 107 108 |
# File 'lib/git/heatmap/period.rb', line 102 def key(t, p = 0) # Month is from 1 - 12, so we shift it to 0 - 11 + years month = (t.month + p) - 1 year = month / 12 mktime(t.year + year, (month % 12) + 1) end |
#name ⇒ Object
98 99 100 |
# File 'lib/git/heatmap/period.rb', line 98 def name "Months" end |