[jbosstools-commits] JBoss Tools SVN: r44009 - trunk/tests/scripts/installation-updates/src/main/groovy.

jbosstools-commits at lists.jboss.org jbosstools-commits at lists.jboss.org
Tue Sep 25 12:03:42 EDT 2012


Author: mickael_istria
Date: 2012-09-25 12:03:42 -0400 (Tue, 25 Sep 2012)
New Revision: 44009

Modified:
   trunk/tests/scripts/installation-updates/src/main/groovy/getAndInstallEclipse.groovy
Log:
JBIDE-12717

Modified: trunk/tests/scripts/installation-updates/src/main/groovy/getAndInstallEclipse.groovy
===================================================================
--- trunk/tests/scripts/installation-updates/src/main/groovy/getAndInstallEclipse.groovy	2012-09-25 15:57:07 UTC (rev 44008)
+++ trunk/tests/scripts/installation-updates/src/main/groovy/getAndInstallEclipse.groovy	2012-09-25 16:03:42 UTC (rev 44009)
@@ -33,9 +33,6 @@
 	new AntBuilder().get(
 		src: downloadURL,
 		dest: cachedFile);
-	if (fileExtension.equals("tar.gz")) {
-		new AntBuilder().gunzip(src: cachedFile.getAbsolutePath());
-	}
 }
 // Unzip
 if (fileExtension.equals("zip")) {
@@ -43,7 +40,11 @@
 		src: cachedFile.getAbsolutePath(),
 		dest: new File().getAbsolutePath());
 } else if (fileExtension.equals("tar.gz")) {
+	File tarFile = new File(eclipseCacheDirectory, cachedFile.getAbsolutePath()[0..- (".gz".length() + 1)]);
+	if (!tarFile.isFile()) {
+		new AntBuilder().gunzip(src: cachedFile.getAbsolutePath(), dest: eclipseCacheDirectory.getAbsolutePath());
+	}
 	new AntBuilder().untar(
-		src: cachedFile.getAbsolutePath()[0..- (".gz".length() + 1)],
+		src: tarFile.getAbsolutePath(),
 		dest: new File(".").getAbsolutePath());
 }
\ No newline at end of file



More information about the jbosstools-commits mailing list