This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
makerel: use Digest::SHA to print sha256sum
[perl5.git] / Porting / perlgov-team-update
CommitLineData
c5df33d3
RS
1#!/usr/bin/env perl
2use v5.30.0;
3use warnings;
98f77c3a 4use Encode qw(encode);
c5df33d3
RS
5use JSON::PP;
6
7my $file = 'Porting/core-team.json';
98f77c3a
RS
8open my $fh, '<:encoding(UTF-8)', $file
9 or die "can't read $file: $!\n";
10
11my $json = do { local $/; <$fh> };
12
13my $data = JSON::PP->new->decode($json);
c5df33d3
RS
14
15my $pod = q{};
16
17for my $key (qw( active inactive )) {
18 $pod .= qq{=head2 \u$key Members\n\n=over 4\n\n};
19
98f77c3a 20 my @items = map {; encode('utf-8', "<$_>") } $data->{$key}->@*;
c5df33d3
RS
21
22 open(my $fh, '-|', 'git', 'check-mailmap', @items)
23 or die "error running check-mailmap: $!";
24
25 my @lines = <$fh>;
26
27 $pod .= "=item $_\n" for sort @lines;
28
29 $pod .= "=back\n\n";
30}
31
32say $pod;