aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xscript/clean-up-dir.sh (renamed from clean-up-dir.sh)0
-rwxr-xr-x[-rw-r--r--]script/refresh-stats.sh0
-rwxr-xr-xscript/reviewer-stats43
3 files changed, 43 insertions, 0 deletions
diff --git a/clean-up-dir.sh b/script/clean-up-dir.sh
index 1f1fc2d67c..1f1fc2d67c 100755
--- a/clean-up-dir.sh
+++ b/script/clean-up-dir.sh
diff --git a/script/refresh-stats.sh b/script/refresh-stats.sh
index c34ccc0bb0..c34ccc0bb0 100644..100755
--- a/script/refresh-stats.sh
+++ b/script/refresh-stats.sh
diff --git a/script/reviewer-stats b/script/reviewer-stats
new file mode 100755
index 0000000000..0a18739e51
--- /dev/null
+++ b/script/reviewer-stats
@@ -0,0 +1,43 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+our $DEBUG = 0;
+
+my $F = $ARGV[0];
+
+my $reviewers = get_reviewer_stats($F);
+show_count($reviewers);
+
+#
+#
+# METHODS
+
+sub get_reviewer_stats {
+ my ($file) = @_;
+
+ my $reviewers = {};
+ open(my $I, '<', $file) or die "$!\n";
+ while(my $r = <$I>) {
+ chomp $r;
+ my($x, $y, $z) = split /\:/, $r, 3;
+
+ $z =~ s/^\s+//g;
+ $x =~ /\-(\d+)\./;
+
+ push @{$reviewers->{$z}}, $1;
+ print "$x: $y: $1: $z\n" if $DEBUG;
+ }
+ close($I);
+
+ return $reviewers;
+}
+
+sub show_count {
+ my ($reviewers) = @_;
+
+ foreach my $auth (sort keys %$reviewers) {
+ print "$auth: ", scalar(@{$reviewers->{$auth}}), "\n";
+ }
+}