From f22ff51a3dfd382980af7bbe495927051ff8b6e7 Mon Sep 17 00:00:00 2001 From: mose Date: Mon, 9 Oct 2023 22:11:00 +0100 Subject: [PATCH] Fixed up some stuff --- build.gradle | 33 +++++---------------------------- 1 file changed, 5 insertions(+), 28 deletions(-) diff --git a/build.gradle b/build.gradle index c8571d7..7e43c6b 100644 --- a/build.gradle +++ b/build.gradle @@ -12,43 +12,19 @@ tasks.withType(JavaCompile) { } tasks.register('buildFolia', Jar) { - def path = project.rootDir.path + "/standalone/" - file(path).mkdirs() - archiveClassifier = 'uber' - archiveFileName = 'ShipsFolia.jar' - destinationDirectory = file(path) - dependsOn ':ShipsForCore:standaloneFolia' dependsOn ':CoreToFolia:plugin' dependsOn configurations.runtimeClasspath - def type = 'Folia' + archiveClassifier = 'uber' + archiveFileName = 'ShipsFolia.jar' - def translateCoreFile = files(project.projectDir.path + '/CoreTo' + type + '/build/libs/TranslateCore' + type + '.jar') - from { - translateCoreFile - configurations.runtimeClasspath.findAll { - it.name.endsWith('jar') && !it.name.contains("junit") && !it.name.contains("hamcrest") - }.collect { - zipTree(it).matching { - exclude "*.txt" - } - } - } -} -tasks.register('buildBukkit', Jar) { def path = project.rootDir.path + "/standalone/" file(path).mkdirs() - it.archiveClassifier = 'uber' - it.archiveFileName = 'ShipsBukkit.jar' destinationDirectory = file(path) - dependsOn ':ShipsForCore:standaloneBukkit' - dependsOn ':CoreToBukkit:plugin' - dependsOn configurations.runtimeClasspath - - def type = 'Bukkit' + def type = 'Folia' def jarFiles = configurations.runtimeClasspath.findAll { it.name.endsWith('jar') && !it.name.contains("junit") && !it.name.contains("hamcrest") @@ -58,12 +34,13 @@ tasks.register('buildBukkit', Jar) { } } - File translateCoreFile = file(project.projectDir.path + '/CoreTo' + type + '/build/libs/TranslateCore' + type + '.jar') + File translateCoreFile = file(project.projectDir.path + '/CoreTo' + type + '/build/libs').listFiles()[0] def coreFiles = zipTree(translateCoreFile) jarFiles.add(coreFiles) from { jarFiles } + } dependencies {