geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject svn commit: r506879 - /geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/library/Library.groovy
Date Tue, 13 Feb 2007 06:08:15 GMT
Author: jdillon
Date: Mon Feb 12 22:08:15 2007
New Revision: 506879

URL: http://svn.apache.org/viewvc?view=rev&rev=506879
Log:
Fixed logging, fail exec on errors

Modified:
    geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/library/Library.groovy

Modified: geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/library/Library.groovy
URL: http://svn.apache.org/viewvc/geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/library/Library.groovy?view=diff&rev=506879&r1=506878&r2=506879
==============================================================================
--- geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/library/Library.groovy
(original)
+++ geronimo/sandbox/build-support/libraries/system/1/groovy/gbuild/system/library/Library.groovy
Mon Feb 12 22:08:15 2007
@@ -60,7 +60,7 @@
         // NOTE: Don't use Ant's chmod task, since it ignors dirs
         //
         
-        ant.exec(executable: 'chmod') {
+        ant.exec(executable: 'chmod', failonerror: true) {
             arg(value: '-R')
             arg(value: perm)
             arg(file: dir)
@@ -85,7 +85,7 @@
         
         ant.mkdir(dir: baseDir)
         
-        ant.exec(executable: 'svn', dir: baseDir) {
+        ant.exec(executable: 'svn', dir: baseDir, failonerror: true) {
             arg(value: 'checkout')
             arg(value: '--non-interactive')
             arg(value: sourceURL)
@@ -103,8 +103,8 @@
         
         assert exists()
         
-        ant.exec(executable: 'svn', dir: baseDir) {
-            arg(value: 'checkin')
+        ant.exec(executable: 'svn', dir: baseDir, failonerror: true) {
+            arg(value: 'commit')
             arg(value: '--non-interactive')
             arg(value: '--message')
             arg(value: message)
@@ -116,7 +116,7 @@
      * Check if the library is the latest revision
      */
     boolean isLatest() {
-        log.info "Checking if library contains the latest changes"
+        log.info "Checking for changes in: $baseDir"
         
         assert exists()
         
@@ -126,7 +126,7 @@
             // Any does not like to replace props, so make a unique one each time
             def propname = 'svnoutput.' + UUID.randomUUID()
             
-            ant.exec(executable: 'svn', dir: baseDir, outputproperty: propname) {
+            ant.exec(executable: 'svn', dir: baseDir, failonerror: true, outputproperty:
propname) {
                 arg(value: 'info')
                 arg(value: '--non-interactive')
                 arg(value: '--xml')
@@ -147,12 +147,12 @@
      * Update the library.
      */
     def update() {
-        log.info "Updating library"
+        log.info "Updating library in: $baseDir"
         
         assert exists()
         
         // Update the local copy
-        ant.exec(executable: 'svn', dir: baseDir) {
+        ant.exec(executable: 'svn', dir: baseDir, failonerror: true) {
             arg(value: 'update')
             arg(value: '--non-interactive')
             arg(file: baseDir)
@@ -163,7 +163,7 @@
      * Remove the library (local workspace)
      */
     def remove() {
-        log.info "Removing library"
+        log.info "Removing library from: $baseDir"
         
         assert exists()
         
@@ -172,7 +172,7 @@
         //       and Ant's mechanism can take forever
         //
         
-        ant.exec(executable: 'rm') {
+        ant.exec(executable: 'rm', failonerror: true) {
             arg(value: '-rf')
             arg(file: baseDir)
         }
@@ -198,9 +198,9 @@
         //       and Ant's mechanism can take forever
         //
         
-        ant.exec(executable: 'cp') {
+        ant.exec(executable: 'cp', failonerror: true) {
             arg(value: '-r')
-            arg(file: baseDir)
+            arg(value: "$baseDir/") // make sure to copy the contents
             arg(file: targetDir)
         }
         



Mime
View raw message