Sha256: 5ae6f06a842a257264043af3768a59d5fe432fb4f547e8a3934f7dab55168c27
Contents?: true
Size: 724 Bytes
Versions: 3
Compression:
Stored size: 724 Bytes
Contents
- block(:hour_of_week) do .blocktable %table %thead %tr %th Weekday - for i in 0..23 %th= i %tbody - max = stats.wday_stats.inject(0) do |r, i| - i[1].inject(r) do |r2, i2| - i2[1].commits > r2 ? i2[1].commits : r2 - for wday in 0..6 %tr %th= weekday(wday) - for hour in 0..23 - d = stats.wday_stats[(wday + 1) % 7] - s = d.nil? ? nil : d[hour] - cnt = s.nil? ? 0 : s.commits - percent = (100 * cnt / max).to_i - if cnt == 0 %td - else %td{:class => "gradient-#{percent}"}= cnt
Version data entries
3 entries across 3 versions & 2 rubygems
Version | Path |
---|---|
gitstats-rb-2.0.0 | template/gnuplot/partials/hour_of_week.haml |
gitstats-ruby-1.0.1 | template/partials/hour_of_week.haml |
gitstats-ruby-1.0.0 | template/partials/hour_of_week.haml |