Changeset 45464 in webkit


Ignore:
Timestamp:
Jul 1, 2009 10:13:41 PM (15 years ago)
Author:
eric@webkit.org
Message:

2009-07-01 Eric Seidel <eric@webkit.org>

Reviewed by Maciej Stachowiak.

prepare-ChangeLog should have a --bug= argument and use it for url autofill
https://bugs.webkit.org/show_bug.cgi?id=26383

prepare-ChangeLog now knows how to grab the bug title from bugs.webkit.org
I also added a bit more template text in an effort to get better ChangeLogs
from casual contributers.

  • Scripts/prepare-ChangeLog:
Location:
trunk/WebKitTools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKitTools/ChangeLog

    r45455 r45464  
     12009-07-01  Eric Seidel  <eric@webkit.org>
     2
     3        Reviewed by Maciej Stachowiak.
     4
     5        prepare-ChangeLog should have a --bug= argument and use it for url autofill
     6        https://bugs.webkit.org/show_bug.cgi?id=26383
     7
     8        prepare-ChangeLog now knows how to grab the bug title from bugs.webkit.org
     9        I also added a bit more template text in an effort to get better ChangeLogs
     10        from casual contributers.
     11
     12        * Scripts/prepare-ChangeLog:
     13
    1142009-07-01  Eric Seidel  <eric@webkit.org>
    215
  • trunk/WebKitTools/Scripts/prepare-ChangeLog

    r45455 r45464  
    9797my $changeLogTimeZone = "PST8PDT";
    9898
     99my $bugNumber;
    99100my $name;
    100101my $emailAddress;
     
    108109my $parseOptionsResult =
    109110    GetOptions("diff|d!" => \$spewDiff,
     111               "bug:i" => \$bugNumber,
    110112               "name:s" => \$name,
    111113               "email:s" => \$emailAddress,
     
    245247print STDERR "  Change author: $name <$emailAddress>.\n";
    246248
     249my $bugDescription;
     250my $bugURL;
     251if ($bugNumber) {
     252    $bugURL = "https://bugs.webkit.org/show_bug.cgi?id=$bugNumber";
     253    my $bugXMLURL = "$bugURL&ctype=xml";
     254    # Perl has no built in XML processing, so we'll fetch and parse with curl and grep
     255    my $descriptionLine = `curl --silent "$bugXMLURL" | grep short_desc`;
     256    $descriptionLine =~ /<short_desc>(.*)<\/short_desc>/;
     257    $bugDescription = $1;
     258    print STDERR "  Description from bug $bugNumber:\n    \"$bugDescription\".\n";
     259}
     260
    247261# Remove trailing parenthesized notes from user name (bit of hack).
    248262$name =~ s/\(.*?\)\s*$//g;
     
    321335    print CHANGE_LOG normalizeLineEndings($description . "\n", $endl) if $description;
    322336
     337    $bugDescription = "SHORT DESCRIPTION/BUG TITLE GOES HERE (OOPS!)" unless $bugDescription;
     338    print CHANGE_LOG normalizeLineEndings("        $bugDescription\n", $endl);
     339
     340    $bugURL = "BUG URL GOES HERE (pass --bug= to autofill)" unless $bugURL;
     341    print CHANGE_LOG normalizeLineEndings("        $bugURL\n\n", $endl);
     342
     343    # We could pre-populate this with the git commit log or with the bug description.
     344    print CHANGE_LOG normalizeLineEndings("        DETAILED DESCRIPTION OF THE CHANGES GOES HERE. (OOPS!) SEE:\n", $endl);
     345    print CHANGE_LOG normalizeLineEndings("        http://webkit.org/coding/contributing.html FOR MORE INFORMATION\n\n", $endl);
     346
    323347    if ($prefix =~ m/WebCore/ || `pwd` =~ m/WebCore/) {
    324348        if ($didChangeRegressionTests) {
    325349            print CHANGE_LOG normalizeLineEndings(testListForChangeLog(sort @addedRegressionTests), $endl);
    326350        } else {
    327             print CHANGE_LOG normalizeLineEndings("        WARNING: NO TEST CASES ADDED OR CHANGED\n\n", $endl);
     351            print CHANGE_LOG normalizeLineEndings("        LIST OF TESTS, OR EXPLANATION WHY TESTING IS IMPOSSIBLE GOES HERE (OOPS!)\n\n", $endl);
    328352        }
    329353    }
Note: See TracChangeset for help on using the changeset viewer.