|
|
@@ -16,6 +16,7 @@ import zlib
|
|
16
|
16
|
|
|
17
|
17
|
GNUPLOT_COMMON = 'set terminal png transparent\nset size 1.0,0.5\n'
|
|
18
|
18
|
ON_LINUX = (platform.system() == 'Linux')
|
|
|
19
|
+WEEKDAYS = ('Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun')
|
|
19
|
20
|
|
|
20
|
21
|
exectime_internal = 0.0
|
|
21
|
22
|
exectime_external = 0.0
|
|
|
@@ -666,9 +667,9 @@ class HTMLReportCreator(ReportCreator):
|
|
666
|
667
|
commits = 0
|
|
667
|
668
|
if d in day_of_week:
|
|
668
|
669
|
commits = day_of_week[d]
|
|
669
|
|
- fp.write('%d %d\n' % (d + 1, commits))
|
|
|
670
|
+ fp.write('%d %s %d\n' % (d + 1, WEEKDAYS[d], commits))
|
|
670
|
671
|
f.write('<tr>')
|
|
671
|
|
- f.write('<th>%d</th>' % (d + 1))
|
|
|
672
|
+ f.write('<th>%s</th>' % (WEEKDAYS[d]))
|
|
672
|
673
|
if d in day_of_week:
|
|
673
|
674
|
f.write('<td>%d (%.2f%%)</td>' % (day_of_week[d], (100.0 * day_of_week[d]) / totalcommits))
|
|
674
|
675
|
else:
|
|
|
@@ -688,7 +689,7 @@ class HTMLReportCreator(ReportCreator):
|
|
688
|
689
|
f.write('</tr>')
|
|
689
|
690
|
|
|
690
|
691
|
for weekday in range(0, 7):
|
|
691
|
|
- f.write('<tr><th>%d</th>' % (weekday + 1))
|
|
|
692
|
+ f.write('<tr><th>%s</th>' % (WEEKDAYS[weekday]))
|
|
692
|
693
|
for hour in range(0, 24):
|
|
693
|
694
|
try:
|
|
694
|
695
|
commits = data.activity_by_hour_of_week[weekday][hour]
|
|
|
@@ -954,7 +955,7 @@ set xrange [0.5:7.5]
|
|
954
|
955
|
set xtics 1
|
|
955
|
956
|
set grid y
|
|
956
|
957
|
set ylabel "Commits"
|
|
957
|
|
-plot 'day_of_week.dat' using 1:2:(0.5) w boxes fs solid
|
|
|
958
|
+plot 'day_of_week.dat' using 1:3:(0.5):xtic(2) w boxes fs solid
|
|
958
|
959
|
""")
|
|
959
|
960
|
f.close()
|
|
960
|
961
|
|