contrib/nitrpg: do stats on merged commits
authorAlexandre Terrasa <alexandre@moz-code.org>
Fri, 6 Feb 2015 22:24:51 +0000 (23:24 +0100)
committerAlexandre Terrasa <alexandre@moz-code.org>
Fri, 6 Feb 2015 22:24:51 +0000 (23:24 +0100)
Signed-off-by: Alexandre Terrasa <alexandre@moz-code.org>

contrib/nitrpg/src/statistics.nit

index cf48978..061722f 100644 (file)
@@ -145,6 +145,9 @@ redef class PullRequestEvent
                        game.stats.inc("pulls_open")
                else if action == "closed" then
                        game.stats.dec("pulls_open")
+                       if pull.merged then
+                               game.stats["commits"] += pull.commits
+                       end
                end
        end
 end