From 7451517d63ceb174268367fe4a5e0782591da1f2 Mon Sep 17 00:00:00 2001 From: Yves Fischer Date: Sat, 21 May 2016 22:40:24 +0200 Subject: stop using intermediate projects for config inheritance --- packages/oraclejdk/oracle.gradle | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 packages/oraclejdk/oracle.gradle (limited to 'packages/oraclejdk/oracle.gradle') diff --git a/packages/oraclejdk/oracle.gradle b/packages/oraclejdk/oracle.gradle new file mode 100644 index 0000000..498b3d7 --- /dev/null +++ b/packages/oraclejdk/oracle.gradle @@ -0,0 +1,34 @@ +buildscript { + repositories { + mavenLocal() + mavenCentral() + } + dependencies { + classpath 'org.xapek.yvesf:gradle-download-task:0.1-SNAPSHOT' + } +} + +task download(type: org.xapek.yvesf.gradle.DownloadTask) {} + +task untar(type: Copy) { + into file("${buildDir}/unpacked/dist") + eachFile { FileCopyDetails fcd -> + fcd.path = fcd.path.substring(path.indexOf('/') + 1) + } +} +untar.dependsOn(download) + +ospackage { + from untar.outputs.files +} + +project.afterEvaluate { + untar.from tarTree(download.destFile) +} + +tasks.getByName('activator').dependsOn('untar') +tasks.getByName('activator').doFirst { + file("${buildDir}/unpacked/dist/bin").list().each { + activator.bin[it] = "/opt/${project.name}/bin/${it}" + } +} -- cgit v1.2.1