Meta/cook: show source URLs for undecided topics
Junio C Hamano committed
Jul 11, 2024 at 14:26 UTC
712aff67e5c6af56d9712438696423796837c7c8
1 file changed
+22
-4
cook
+22
-4
index 5fb2062574..1dd676463b 100755
--- a/cook
+++ b/cook
@@ -918,14 +918,24 @@ sub wildo {
next unless defined $topic && $in_desc;
s/^\s+//;
+
+ if (/Originally merged to 'next' on ([-0-9]+)/) {
+ $topic->[1] = $1;
+ next;
+ }
+
if (wildo_match($_)) {
wildo_queue(\%what, $_, $topic);
- $topic = $in_desc = undef;
+ next;
}
- if (/Originally merged to 'next' on ([-0-9]+)/) {
- $topic->[1] = $1;
+ if (/^source:\s+(.*)$/) {
+ $topic->[5] ||= [];
+ push @{$topic->[5]}, $1;
+ $topic = $in_desc = undef;
+ next;
}
+
}
wildo_flush_topic($in_section, \%what, $topic);
@@ -935,7 +945,7 @@ sub wildo {
for $topic (sort { (($a->[1] cmp $b->[1]) ||
($a->[0] cmp $b->[0])) }
@{$what{$what}}) {
- my ($tip, $next, $name, $count, $seen) = @$topic;
+ my ($tip, $next, $name, $count, $seen, $source) = @$topic;
my ($sign);
$tip =~ s/^\d{4}-//;
if (($next eq $too_recent) || (0 < $seen)) {
@@ -947,6 +957,14 @@ sub wildo {
}
$count = "#$count";
printf " %s %-60s %s%s %5s\n", $sign, $name, $tip, $next, $count;
+ if ($what !~ /^Will /) {
+ for my $s (@$source) {
+ if ($s =~ /^<(.*)>$/) {
+ $s = "https://lore.kernel.org/git/$1/";
+ }
+ printf " $s\n";
+ }
+ }
}
$ipbl = "\n";
}