This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perlgov-team-update: to generate new perlgov member listing
authorRicardo Signes <rjbs@semiotic.systems>
Sat, 26 Jun 2021 16:23:28 +0000 (12:23 -0400)
committerRicardo Signes <rjbs@semiotic.systems>
Mon, 2 Aug 2021 13:35:11 +0000 (09:35 -0400)
I hate this program.  I had a hard time clearing my mind to write it, so
it is bad, but it works.

Porting/perlgov-team-update [new file with mode: 0644]

diff --git a/Porting/perlgov-team-update b/Porting/perlgov-team-update
new file mode 100644 (file)
index 0000000..f572718
--- /dev/null
@@ -0,0 +1,26 @@
+#!/usr/bin/env perl
+use v5.30.0;
+use warnings;
+use JSON::PP;
+
+my $file = 'Porting/core-team.json';
+my $data = JSON::PP->new->decode(scalar `cat $file`);
+
+my $pod = q{};
+
+for my $key (qw( active inactive )) {
+  $pod .= qq{=head2 \u$key Members\n\n=over 4\n\n};
+
+  my @items = map {; "<$_>" } $data->{$key}->@*;
+
+  open(my $fh, '-|', 'git', 'check-mailmap', @items)
+    or die "error running check-mailmap: $!";
+
+  my @lines = <$fh>;
+
+  $pod .= "=item $_\n" for sort @lines;
+
+  $pod .= "=back\n\n";
+}
+
+say $pod;