From c40854fc2214a895f386e71b284422d67ef69007 Mon Sep 17 00:00:00 2001 From: Brian O'Neill Date: Tue, 3 May 2016 14:33:11 -0400 Subject: [PATCH 1/2] Adding dependencies between the tasks --- build.gradle | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index 17f7649..b04163a 100644 --- a/build.gradle +++ b/build.gradle @@ -13,7 +13,7 @@ targetCompatibility = 1.8 release { versionPropertyFile = 'gradle.properties' - buildTasks = ['build', 'copyRuntimeLibs', 'batchZip'] + buildTasks = ['build', 'dist'] scmAdapters = [ net.researchgate.release.GitAdapter ] @@ -64,7 +64,7 @@ task copyRuntimeLibs(type: Copy) { into 'build/libs' } -task batchZip(type: Zip) { +task zipDistribution(dependsOn: 'copyRuntimeLibs', type: Zip) { into("koupler-${version}") { from 'LICENSE.txt' from 'README.md' @@ -81,3 +81,14 @@ task batchZip(type: Zip) { } } } + +task dist (dependsOn: 'zipDistribution', type: Copy){ + from 'build/distributions/' + include '*.zip' + into 'releases' +} + +clean{ + delete "target" +} + From 3961ecf96c7222d9d5078e905bd3a442eb25f9ed Mon Sep 17 00:00:00 2001 From: Brian O'Neill Date: Tue, 3 May 2016 14:53:34 -0400 Subject: [PATCH 2/2] Proper dependencies through the build chain --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index b04163a..c3a2ed2 100644 --- a/build.gradle +++ b/build.gradle @@ -59,7 +59,7 @@ dependencies { compile group: 'org.eclipse.jetty', name: 'jetty-http', version:'9.0.2.v20130417' } -task copyRuntimeLibs(type: Copy) { +task copyRuntimeLibs(dependsOn: 'build', type: Copy) { from configurations.runtime into 'build/libs' }