git-pretty-stats icon indicating copy to clipboard operation
git-pretty-stats copied to clipboard

Statistics for date range

Open ahilles107 opened this issue 11 years ago • 1 comments

Would be nice to have this feature. For now we can get this by modifying gitter.

--- /var/www/git-stats/vendor/klaussilveira/gitter/lib/Gitter/Repository.php
@@ -11,7 +11,10 @@
         foreach ($logs as $log) {
             $commit = new Commit;
             $commit->importData($log);
-            $commits[] = $commit;
+            $date = new \Gitter\Util\DateTime('2013-01-01 00:00:00');
+            if ($commit->getDate() > $date) {
+                $commits[] = $commit;
+            }
         }

         return $commits;

ahilles107 avatar Dec 28 '13 14:12 ahilles107

This is definitely a feature that is going to be implemented somewhere in the near future.

modess avatar Dec 28 '13 19:12 modess