Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Waibel2018-06-29 14:27:20 -0400
committerFlorian Waibel2018-06-29 14:27:20 -0400
commit2be32b8fc6d53261e073f145224c82722bb88fd1 (patch)
treecbed0054832f5fddcb58a65f26ef6d103c2b251d
parentd8cbed322d3322feb10953fde641c50f9e9f3778 (diff)
downloadorg.eclipse.virgo.samples-2be32b8fc6d53261e073f145224c82722bb88fd1.tar.gz
org.eclipse.virgo.samples-2be32b8fc6d53261e073f145224c82722bb88fd1.tar.xz
org.eclipse.virgo.samples-2be32b8fc6d53261e073f145224c82722bb88fd1.zip
Update recipe-custome-virgo
Only unzip the runtime, if available.
-rw-r--r--recipe-custom-virgo/recipe-custom-virgo-runtime/build.gradle11
1 files changed, 7 insertions, 4 deletions
diff --git a/recipe-custom-virgo/recipe-custom-virgo-runtime/build.gradle b/recipe-custom-virgo/recipe-custom-virgo-runtime/build.gradle
index a1405e7..f300ab1 100644
--- a/recipe-custom-virgo/recipe-custom-virgo-runtime/build.gradle
+++ b/recipe-custom-virgo/recipe-custom-virgo-runtime/build.gradle
@@ -34,11 +34,14 @@ dependencies {
task unzipRuntime(type: Copy, dependsOn: dockerize) {
outputs.upToDateWhen { false } // always unzip
- def tarFile = new groovy.util.FileNameByRegexFinder().getFileNames("${->project.buildDir.absolutePath}", /.*\.tar/).get(0)
- def outputDir = file("${buildDir}")
+ def fileNames = new FileNameByRegexFinder().getFileNames("${-> project.buildDir.absolutePath}", /.*\.tar/)
+ if (fileNames) {
+ def tarFile = fileNames.get(0)
+ def outputDir = file("${buildDir}")
- from tarTree(tarFile)
- into outputDir
+ from tarTree(tarFile)
+ into outputDir
+ }
}
// tag::task_start_virgo_runtime[]

Back to the top