]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Meta/cook: show source URLs for undecided topics
authorJunio C Hamano <gitster@pobox.com>
Thu, 11 Jul 2024 21:26:33 +0000 (14:26 -0700)
committerJunio C Hamano <gitster@pobox.com>
Thu, 11 Jul 2024 21:26:33 +0000 (14:26 -0700)
cook

diff --git a/cook b/cook
index 5fb2062574a6907ebbcfffe70a618c02c0858891..1dd676463bccabb07a03f98f3786a7f788ea8349 100755 (executable)
--- 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";
        }