264 for (const auto &[repo, authors] : heatmap.data()) { |
266 for (const auto &[repo, authors] : heatmap.data()) { |
265 bool h1_rendered = false; |
267 bool h1_rendered = false; |
266 for (const auto &[author, entries] : authors) { |
268 for (const auto &[author, entries] : authors) { |
267 if (settings.exclude_author(author)) continue; |
269 if (settings.exclude_author(author)) continue; |
268 if (!h1_rendered) { |
270 if (!h1_rendered) { |
269 html::h1(repo); |
271 html::heading_repo(repo); |
270 h1_rendered = true; |
272 h1_rendered = true; |
271 } |
273 } |
272 html::h2(author); |
274 |
273 html::table_begin(report_year); |
275 const auto commits_per_month = heatmap.commits_per_month(repo, author, report_year); |
|
276 const auto total_commits = std::accumulate(commits_per_month.begin(), commits_per_month.end(), 0u); |
|
277 html::heading_author(author, total_commits); |
|
278 html::table_begin(report_year, commits_per_month); |
274 |
279 |
275 // initialize counters |
280 // initialize counters |
276 unsigned column = 0, row = 0; |
281 unsigned column = 0, row = 0; |
277 |
282 |
278 // initialize first day (which must be a Monday, possibly the year before) |
283 // initialize first day (which must be a Monday, possibly the year before) |