geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject svn commit: r516244 - /geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/util/ShellExecutor.groovy
Date Fri, 09 Mar 2007 01:02:43 GMT
Author: jdillon
Date: Thu Mar  8 17:02:42 2007
New Revision: 516244

URL: http://svn.apache.org/viewvc?view=rev&rev=516244
Log:
Split up the script into multi-line for better output handling

Modified:
    geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/util/ShellExecutor.groovy

Modified: geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/util/ShellExecutor.groovy
URL: http://svn.apache.org/viewvc/geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/util/ShellExecutor.groovy?view=diff&rev=516244&r1=516243&r2=516244
==============================================================================
--- geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/util/ShellExecutor.groovy
(original)
+++ geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/util/ShellExecutor.groovy
Thu Mar  8 17:02:42 2007
@@ -38,12 +38,7 @@
     
     def ShellExecutor(String script) {
         body << '#!/bin/sh'
-        if (script) {
-            // Split up the script into multi-line for better output handling
-            new StringReader(script).eachLine { line ->
-                body << line
-            }
-        }
+        this << script
     }
     
     def ShellExecutor() {
@@ -53,7 +48,10 @@
     def leftShift(String text) {
         assert text
         
-        body << text
+        // Split up the script into multi-line for better output handling
+        new StringReader(text).eachLine { line ->
+            body << line
+        }
     }
     
     def execute(List args) {



Mime
View raw message