* [FFmpeg-devel] [PATCH v2 0/1] tools/general_assembly.pl - add options to print names, emails or both [not found] <20231106184141.30439-1-cosmin@cosmin.at> @ 2023-11-06 18:41 ` Cosmin Stejerean via ffmpeg-devel [not found] ` <20231106184141.30439-2-cosmin@cosmin.at> 1 sibling, 0 replies; 4+ messages in thread From: Cosmin Stejerean via ffmpeg-devel @ 2023-11-06 18:41 UTC (permalink / raw) To: ffmpeg-devel; +Cc: Cosmin Stejerean Per http://ffmpeg.org/pipermail/ffmpeg-devel/2023-November/316480.html a list of emails should not be published as the GA membership. To facilitate publishing the GA list this updates the GA script with options to print only names, only emails (for voting) or both. Changes since v1: - added --emails to print only emails with compatibility with voting software - added --names to make it easy to get a list of only names for publishing - added help message to show usage Cosmin Stejerean (1): tools/general_assembly.pl - add options to print names, emails or both tools/general_assembly.pl | 43 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 41 insertions(+), 2 deletions(-) -- 2.42.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". ^ permalink raw reply [flat|nested] 4+ messages in thread
[parent not found: <20231106184141.30439-2-cosmin@cosmin.at>]
* [FFmpeg-devel] [PATCH v2 1/1] tools/general_assembly.pl - add options to print names, emails or both [not found] ` <20231106184141.30439-2-cosmin@cosmin.at> @ 2023-11-06 18:41 ` Cosmin Stejerean via ffmpeg-devel 2023-11-06 23:53 ` Stefano Sabatini 2023-11-14 17:47 ` Anton Khirnov 0 siblings, 2 replies; 4+ messages in thread From: Cosmin Stejerean via ffmpeg-devel @ 2023-11-06 18:41 UTC (permalink / raw) To: ffmpeg-devel; +Cc: Cosmin Stejerean Signed-off-by: Cosmin Stejerean <cosmin@cosmin.at> --- tools/general_assembly.pl | 43 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 41 insertions(+), 2 deletions(-) diff --git a/tools/general_assembly.pl b/tools/general_assembly.pl index 898a6262ef..8204d89794 100644 --- a/tools/general_assembly.pl +++ b/tools/general_assembly.pl @@ -6,9 +6,41 @@ use strict; use POSIX qw(strftime); use Encode qw(decode); use Data::Dumper; +use Getopt::Long; + +binmode(STDOUT, ":utf8"); sub trim { my $s = shift; $s =~ s/^\s+|\s+$//g; return $s }; +sub print_help { + print "Usage: $0 [options]\n"; + print "Options:\n"; + print " --names Print only the names\n"; + print " --emails Print only the email addresses\n"; + print " --full Print both names and email addresses (default)\n"; + print " -h, --help Show this help message\n"; + exit; +} + +my $print_full = 1; +my $print_names = 0; +my $print_emails = 0; +my $help = 0; + +GetOptions( + "full" => \$print_full, + "names" => \$print_names, + "emails" => \$print_emails, + "help" => \$help, + "h" => \$help, +); + +print_help() if $help; + +if ($print_names || $print_emails) { + $print_full = 0; +} + my @shortlog = split /\n/, decode('UTF-8', `git log --pretty=format:"%aN <%aE>" --since="last 36 months" | sort | uniq -c | sort -r`, Encode::FB_CROAK); my %assembly = (); @@ -35,6 +67,13 @@ foreach my $line (@shortlog) { } printf("# %s %s", strftime("%Y-%m-%d", localtime), decode('UTF-8', `git rev-parse HEAD`, Encode::FB_CROAK)); -foreach my $email (sort values %assembly) { - printf("%s\n", $email); +foreach my $name (sort keys %assembly) { + my $email = $assembly{$name}; + if ($print_full) { + printf("%s <%s>\n", $name, $email); + } elsif ($print_names) { + printf("%s\n", $name); + } elsif ($print_emails) { + printf("%s\n", $email); + } } -- 2.42.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [FFmpeg-devel] [PATCH v2 1/1] tools/general_assembly.pl - add options to print names, emails or both 2023-11-06 18:41 ` [FFmpeg-devel] [PATCH v2 1/1] " Cosmin Stejerean via ffmpeg-devel @ 2023-11-06 23:53 ` Stefano Sabatini 2023-11-14 17:47 ` Anton Khirnov 1 sibling, 0 replies; 4+ messages in thread From: Stefano Sabatini @ 2023-11-06 23:53 UTC (permalink / raw) To: FFmpeg development discussions and patches; +Cc: Cosmin Stejerean On date Monday 2023-11-06 18:41:54 +0000, ffmpeg-devel Mailing List wrote: > Signed-off-by: Cosmin Stejerean <cosmin@cosmin.at> > --- > tools/general_assembly.pl | 43 +++++++++++++++++++++++++++++++++++++-- > 1 file changed, 41 insertions(+), 2 deletions(-) > > diff --git a/tools/general_assembly.pl b/tools/general_assembly.pl > index 898a6262ef..8204d89794 100644 > --- a/tools/general_assembly.pl > +++ b/tools/general_assembly.pl > @@ -6,9 +6,41 @@ use strict; > use POSIX qw(strftime); > use Encode qw(decode); > use Data::Dumper; > +use Getopt::Long; > + > +binmode(STDOUT, ":utf8"); > > sub trim { my $s = shift; $s =~ s/^\s+|\s+$//g; return $s }; > > +sub print_help { > + print "Usage: $0 [options]\n"; > + print "Options:\n"; > + print " --names Print only the names\n"; > + print " --emails Print only the email addresses\n"; > + print " --full Print both names and email addresses (default)\n"; > + print " -h, --help Show this help message\n"; > + exit; while at it: use Pod::Usage; ... Getopt::Long::Configure ("bundling"); ... 'help|usage|h' => sub { pod2usage( -verbose => 1, -exitval => 0) }, > +} > + > +my $print_full = 1; > +my $print_names = 0; > +my $print_emails = 0; > +my $help = 0; > + > +GetOptions( > + "full" => \$print_full, > + "names" => \$print_names, > + "emails" => \$print_emails, > + "help" => \$help, > + "h" => \$help, > +); > + > +print_help() if $help; > + > +if ($print_names || $print_emails) { > + $print_full = 0; > +} > + > my @shortlog = split /\n/, decode('UTF-8', `git log --pretty=format:"%aN <%aE>" --since="last 36 months" | sort | uniq -c | sort -r`, Encode::FB_CROAK); > my %assembly = (); > > @@ -35,6 +67,13 @@ foreach my $line (@shortlog) { > } > > printf("# %s %s", strftime("%Y-%m-%d", localtime), decode('UTF-8', `git rev-parse HEAD`, Encode::FB_CROAK)); > -foreach my $email (sort values %assembly) { > - printf("%s\n", $email); > +foreach my $name (sort keys %assembly) { > + my $email = $assembly{$name}; > + if ($print_full) { > + printf("%s <%s>\n", $name, $email); > + } elsif ($print_names) { > + printf("%s\n", $name); > + } elsif ($print_emails) { > + printf("%s\n", $email); > + } LGTM anyway. _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [FFmpeg-devel] [PATCH v2 1/1] tools/general_assembly.pl - add options to print names, emails or both 2023-11-06 18:41 ` [FFmpeg-devel] [PATCH v2 1/1] " Cosmin Stejerean via ffmpeg-devel 2023-11-06 23:53 ` Stefano Sabatini @ 2023-11-14 17:47 ` Anton Khirnov 1 sibling, 0 replies; 4+ messages in thread From: Anton Khirnov @ 2023-11-14 17:47 UTC (permalink / raw) To: ffmpeg-devel; +Cc: Cosmin Stejerean Pushed. And sorry, I didn't notice that the ML mangled your email :/ -- Anton Khirnov _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-11-14 17:47 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <20231106184141.30439-1-cosmin@cosmin.at> 2023-11-06 18:41 ` [FFmpeg-devel] [PATCH v2 0/1] tools/general_assembly.pl - add options to print names, emails or both Cosmin Stejerean via ffmpeg-devel [not found] ` <20231106184141.30439-2-cosmin@cosmin.at> 2023-11-06 18:41 ` [FFmpeg-devel] [PATCH v2 1/1] " Cosmin Stejerean via ffmpeg-devel 2023-11-06 23:53 ` Stefano Sabatini 2023-11-14 17:47 ` Anton Khirnov
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git