From: Ivan Dubrov Date: Mon, 28 Apr 2014 20:30:49 +0000 (-0700) Subject: Do not copy data in installer build when don't have any X-Git-Tag: full-7u51+3^0 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=f6872d68a9fca76623a44cd97eb2979b4b2785f8;p=dcevm.git Do not copy data in installer build when don't have any --- diff --git a/installer/build.gradle b/installer/build.gradle index f49ba255..98952219 100644 --- a/installer/build.gradle +++ b/installer/build.gradle @@ -27,9 +27,12 @@ sourceSets { } } -task copyData << { - Files.createDirectories(processedData) - Files.walkFileTree(dataSource, new CopyDataVisitor(project)); +task copyData { + onlyIf { Files.exists(dataSource) } + doLast { + Files.createDirectories(processedData) + Files.walkFileTree(dataSource, new CopyDataVisitor(project)); + } } class CopyDataVisitor extends SimpleFileVisitor {