From 251c23c2ba06fd97139b4e0d5665ffd90858ff4e Mon Sep 17 00:00:00 2001 From: mosemister Date: Wed, 11 Oct 2023 16:50:48 +0100 Subject: [PATCH] Fixed build --- build.gradle | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/build.gradle b/build.gradle index 7e43c6b..800bbc5 100644 --- a/build.gradle +++ b/build.gradle @@ -20,6 +20,7 @@ tasks.register('buildFolia', Jar) { archiveFileName = 'ShipsFolia.jar' + def path = project.rootDir.path + "/standalone/" file(path).mkdirs() destinationDirectory = file(path) @@ -34,11 +35,13 @@ tasks.register('buildFolia', Jar) { } } - File translateCoreFile = file(project.projectDir.path + '/CoreTo' + type + '/build/libs').listFiles()[0] - def coreFiles = zipTree(translateCoreFile) - jarFiles.add(coreFiles) - from { - jarFiles + File translateCoreFile = file(project.projectDir.path + '/CoreTo' + type + '/build/libs/TranslateCoreFolia') + if(translateCoreFile.exists()) { + def coreFiles = zipTree(translateCoreFile) + jarFiles.add(coreFiles) + from { + jarFiles + } } }