<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -3,7 +3,7 @@ use strict;
 use warnings;
 use vars qw($VERSION);
 
-$VERSION = '1.56_11';
+$VERSION = '1.56_12';
 
 =head1 NAME
 
@@ -167,6 +167,7 @@ Print the script version and CPAN.pm version then exit.
 use autouse Carp =&gt; qw(carp croak cluck);
 use CPAN ();
 use autouse Cwd =&gt; qw(cwd);
+use autouse 'Data::Dumper' =&gt; qw(Dumper);
 use File::Spec::Functions;
 use File::Basename;
 
@@ -334,10 +335,13 @@ sub run
 	$logger-&gt;debug( &quot;Using logger from @{[ref $logger]}&quot; );
 
 	$class-&gt;_hook_into_CPANpm_report;
+	$logger-&gt;debug( &quot;Hooked into output&quot; );
 
 	$class-&gt;_stupid_interface_hack_for_non_rtfmers;
+	$logger-&gt;debug( &quot;Patched cargo culting&quot; );
 
 	my $options = $class-&gt;_process_options;
+	$logger-&gt;debug( &quot;Options are @{[Dumper($options)]}&quot; );
 
 	$class-&gt;_process_setup_options( $options );
 
@@ -491,7 +495,7 @@ BEGIN {
 my @skip_lines = (
 	qr/^\QWarning \(usually harmless\)/,
 	qr/\bwill not store persistent state\b/,
-	qr(^//hint//),
+	qr(//hint//),
 	qr/^\s+reports\s+/,
 	);
 
@@ -501,11 +505,20 @@ sub _get_cpanpm_last_line
 	
 	my @lines = &lt;$fh&gt;;
 	
+    # This is a bit ugly. Once we examine a line, we have to
+    # examine the line before it and go through all of the same
+    # regexes. I could do something fancy, but this works.
+    REGEXES: {
 	foreach my $regex ( @skip_lines )
 		{
-		pop @lines if $lines[-1] =~ m/$regex/;
+		if( $lines[-1] =~ m/$regex/ )
+            {
+            pop @lines;
+            redo REGEXES; # we have to go through all of them for every line!
+            }
 		}
-	
+    }
+    
     $logger-&gt;debug( &quot;Last interesting line of CPAN.pm output is:\n\t$lines[-1]&quot; );
     
 	$lines[-1];</diff>
      <filename>lib/Cpan.pm</filename>
    </modified>
    <modified>
      <diff>@@ -3,7 +3,7 @@ use strict;
 use vars qw($VERSION);
 
 use App::Cpan;
-$VERSION = '1.56_11';
+$VERSION = '1.56_12';
 
 my $rc = App::Cpan-&gt;run( @ARGV );
 </diff>
      <filename>script/cpan</filename>
    </modified>
    <modified>
      <diff>@@ -2,7 +2,7 @@
 use strict;
 use warnings;
 
-use Test::More tests =&gt; 59;
+use Test::More tests =&gt; 60;
 
 # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
 my $CPAN = 'CPAN::Shell';
@@ -112,6 +112,25 @@ _clear();
 }
 
 # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
+{
+my $message = &lt;&lt;'HERE';
+Result: FAIL
+  D:/Workspace/CI/DRW-Perl/DRW-Module-Build/distributions/DRW-Module-Build/.
+  C:\strawberry\\perl\\bin\\perl.exe ./Build test -- NOT OK
+//hint// to see the cpan-testers results for installing this module, try:
+  reports D:/Workspace/CI/DRW-Perl/DRW-Module-Build/distributions/DRW-Module-Build/.
+Directory 'D:/Workspace/CI/DRW-Perl/DRW-Module-Build/distributions/DRW-Module-Build/.' not below D:\Workspace\drwperl\build, will not store persistent state
+HERE
+
+$CPAN-&gt;_clear_cpanpm_output;
+$CPAN-&gt;myprint( $message );
+
+my $last_line = $class-&gt;_get_cpanpm_last_line();
+like( $last_line, qr/NOT OK/, 'Last line is NOT OK line' );
+
+}
+
+# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
 sub my_clear_and_get
 	{
 	my( $method, $message ) = @_;</diff>
      <filename>t/cpanpm_output_hook.t</filename>
    </modified>
    <modified>
      <diff>@@ -2,6 +2,8 @@
 use strict;
 use warnings;
 
+$|++;
+
 use Test::More tests =&gt; 10;
 
 use File::Spec::Functions qw(catfile devnull);
@@ -36,7 +38,7 @@ diag( &lt;&lt;&quot;HERE&quot; );
 =================================================================
 You're going to see a mess of output. This is normal and it comes
 from the external process I am testing. I'm intentionally trying
-to install modules that will fail.
+to install modules that will fail. I'll tell you when I'm done.
 =================================================================
 
 
@@ -56,3 +58,14 @@ foreach my $trial ( @trials )
 	
 	is( $exit_value, $expected_exit_value, &quot;$command @config @$options&quot; );
 	}
+
+diag( &lt;&lt;&quot;HERE&quot; );
+
+
+
+=================================================================
+I'm done. Any further messes you see are real errors.
+=================================================================
+
+
+HERE</diff>
      <filename>t/return_values.t</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>5e3ee1b0d1ec69745060f202eeb50922b58a0646</id>
    </parent>
  </parents>
  <author>
    <name>bfoy</name>
    <email>bfoy@WWD-BFOY01.US.DRWHoldings.com</email>
  </author>
  <url>http://github.com/briandfoy/cpan-script/commit/287e7db81f9316d407a844b5f402fdf6146fd870</url>
  <id>287e7db81f9316d407a844b5f402fdf6146fd870</id>
  <committed-date>2009-03-19T20:31:11-07:00</committed-date>
  <authored-date>2009-03-19T20:31:11-07:00</authored-date>
  <message>* Run all regexes against all lines as I look for the real status line</message>
  <tree>bec9c801733ce1cb88f3400ae1f944a20b4d276e</tree>
  <committer>
    <name>bfoy</name>
    <email>bfoy@WWD-BFOY01.US.DRWHoldings.com</email>
  </committer>
</commit>
