Patch to ports-mgmt/portupdate-scan to deal with problems which have surfaced recently, parsing the files /usr/ports/MOVED and /usr/ports/UPDATING. MOVED had an extra blank line on the end for awhile, and the case of some of the UPDATING lines have changed (e.g., Author: instead of AUTHOR:). This patch allows portupdate-scan to tolerate these variances. I don't have permission to commit this change to CVS myself. Fix: PORTNAME= portupdate-scan -PORTVERSION= 0.2 +PORTVERSION= 0.3 CATEGORIES= ports-mgmt MASTER_SITES= # none DISTFILES= # none use Text::ParseWords; use Getopt::Std; @@ -41,7 +42,7 @@ } sub VERSION_MESSAGE() { - print "portupdate-scan 0.1\n"; + print "portupdate-scan 0.3\n"; } # Fetch cmdline args, display usage if appropriate @@ -82,10 +83,10 @@ my ($affects, $remainder, $line); my $index = 0; foreach $line (@_) { - if ($line =~ /^\s*AFFECTS:/) { + if ($line =~ /^\s*AFFECTS:/i) { $affects = $line; $remainder = $index; - } elsif ($affects and $line =~ /^\s*AUTHOR/) { + } elsif ($affects and $line =~ /^\s*AUTHOR/i) { last; } elsif ($affects) { $affects .= $line; @@ -317,7 +318,9 @@ open(MOVED, $movedFile) or die "Can't open $movedFile: $!"; while(<MOVED>) { chomp; - if ($_ !~ /^\s*#/) { + if ($_ =~ /^\s*$/) { + print "+ Ignoring MOVED line containing no non-whitespace chars.\n" if $opt{d}; + } elsif ($_ !~ /^\s*#/) { my ($from, $to) = ($_ =~ /^([^|]*)\|([^|]*)/) or die "$_ is not a correctly formed MOVED line";--P32QO7CVQF0PCjwZ2GC5ndmsTzC6KI5mf3QS5PkGdVLVxzvc Content-Type: text/plain; name="file.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="file.diff" diff -ruN portupdate-scan-0.2/Makefile /usr/ports/ports-mgmt/portupdate-scan/Makefile --- portupdate-scan-0.2/Makefile Mon Feb 4 09:26:19 2008 +++ /usr/ports/ports-mgmt/portupdate-scan/Makefile Mon Jul 21 15:35:58 2008 @@ -7,7 +7,7 @@ # This port is self contained in the files directory. How-To-Repeat: N/A
Class Changed From-To: sw-bug->maintainer-update Fix category (submitter is maintainer) (via the GNATS Auto Assign Tool)
Responsible Changed From-To: freebsd-ports-bugs->beech I'll take it
beech 2008-07-24 18:18:03 UTC FreeBSD ports repository Modified files: ports-mgmt/portupdate-scan Makefile ports-mgmt/portupdate-scan/src portupdate-scan Log: - Patch to ports-mgmt/portupdate-scan to deal with problems which have surfaced recently, parsing the files /usr/ports/MOVED and /usr/ports/UPDATING. MOVED had an extra blank line on the end for awhile, and the case of some of the UPDATING lines have changed (e.g., Author: instead of AUTHOR:). This patch allows portupdate-scan to tolerate these variances. PR: ports/125840 Submitted by: Alex Stangl <alex@stangl.us> (maintainer) Revision Changes Path 1.3 +1 -1 ports/ports-mgmt/portupdate-scan/Makefile 1.3 +8 -5 ports/ports-mgmt/portupdate-scan/src/portupdate-scan _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: open->closed Committed, Thanks! Note: In the future please roll your diffs so they apply from the base of the port itself, not from /usr/ports/foo, thanks.