[Bps-public-commit] r15004 - in Shipwright/branches/2.0: lib/Shipwright

sunnavy at bestpractical.com sunnavy at bestpractical.com
Mon Aug 11 12:22:50 EDT 2008


Author: sunnavy
Date: Mon Aug 11 12:22:49 2008
New Revision: 15004

Modified:
   Shipwright/branches/2.0/   (props changed)
   Shipwright/branches/2.0/lib/Shipwright/Util.pm

Log:
 r15553 at sunnavys-mb:  sunnavy | 2008-08-12 00:18:31 +0800
 tiny change


Modified: Shipwright/branches/2.0/lib/Shipwright/Util.pm
==============================================================================
--- Shipwright/branches/2.0/lib/Shipwright/Util.pm	(original)
+++ Shipwright/branches/2.0/lib/Shipwright/Util.pm	Mon Aug 11 12:22:49 2008
@@ -61,13 +61,18 @@
     Shipwright::Util->select('stdout');
 
     $log->info("run output:\n$out") if $out;
-    $log->warn("run err:\n$err")    if $err;
+    $log->error("run err:\n$err")    if $err;
 
     if ($?) {
         $log->error(
             'failed to run ' . join( ' ', @$cmd ) . " with exit number $?" );
-
-        die "something wrong when execute @$cmd: $?" unless $ignore_failure;
+        unless ($ignore_failure) {
+            die <<"EOF";
+something wrong when execute @$cmd: $?
+the output is: $out
+the error is: $err
+EOF
+        }
     }
 
     return wantarray ? ( $out, $err ) : $out;



More information about the Bps-public-commit mailing list