This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Integrate:
authorNicholas Clark <nick@ccl4.org>
Fri, 13 Jan 2006 17:45:49 +0000 (17:45 +0000)
committerNicholas Clark <nick@ccl4.org>
Fri, 13 Jan 2006 17:45:49 +0000 (17:45 +0000)
[ 26713]
Add an option 'opened' which reports on the maintainers of all files
perforce currently has open.

[ 26747]
Cope with change entries that are \r terminated
p4raw-link: @26747 on //depot/perl: 77ebfeacf485ddf164803294eee13949ad1cfe79
p4raw-link: @26713 on //depot/perl: d933dc9eee7771e117a050289ed31b0286699d55

p4raw-id: //depot/maint-5.8/perl@26829
p4raw-integrated: from //depot/perl@26828 'copy in' Porting/genlog
(@18767..) Porting/Maintainers.pm (@21408..)

Porting/Maintainers.pm
Porting/genlog

index b8959e8..f71db98 100644 (file)
@@ -72,6 +72,7 @@ $0: Usage: $0 [[--maintainer M --module M --files --check]|file ...]
 --module M     list all modules matching M
 --files                list all files
 --check                check consistency of Maintainers.pl
+--opened       list all modules of files opened by perforce
 Matching is case-ignoring regexp, author matching is both by
 the short id and by the full name and email.  A "module" may
 not be just a module, it may be a file or files or a subdirectory.
@@ -84,6 +85,7 @@ my $Maintainer;
 my $Module;
 my $Files;
 my $Check;
+my $Opened;
 
 sub process_options {
     usage()
@@ -93,9 +95,18 @@ sub process_options {
                       'module=s'       => \$Module,
                       'files'          => \$Files,
                       'check'          => \$Check,
+                      'opened'         => \$Opened,
                      );
 
-    my @Files = @ARGV;
+    my @Files;
+   
+    if ($Opened) {
+       my @raw = `p4 opened`;
+       die if $?;
+       @Files =  map {s!#.*!!s; s!^//depot/.*?/perl/!!; $_} @raw;
+    } else {
+       @Files = @ARGV;
+    }
 
     usage() if @Files && ($Maintainer || $Module || $Files);
 
index 98bccdd..9926b37 100755 (executable)
@@ -69,6 +69,7 @@ if ($?) {
     die "$0: `p4 -p $p4port describe -s @changes` failed, status[$?]\n";
 }
 else {
+    tr/\r/\n/ foreach @desc;
     chomp @desc;
     while (@desc) {
        my ($change,$who,$date,$time,@log,$branch,$file,$type,%files);