From 1cca2182a97ebe035c9e7a03fdbb1ee0344019c2 Mon Sep 17 00:00:00 2001 From: Matthew Miller Date: Sun, 13 Oct 2019 22:06:54 +1000 Subject: [PATCH] Fixed gradle setup --- worldedit-core/build.gradle.kts | 44 +++++++++++++++------------------ 1 file changed, 20 insertions(+), 24 deletions(-) diff --git a/worldedit-core/build.gradle.kts b/worldedit-core/build.gradle.kts index e03d384fb..877199c84 100644 --- a/worldedit-core/build.gradle.kts +++ b/worldedit-core/build.gradle.kts @@ -90,29 +90,25 @@ sourceSets { val crowdinApiKey = "crowdin_apikey" -fun Project.applyPlatformCrowdInConfig() { - if (!project.hasProperty(crowdinApiKey)) ext[crowdinApiKey] = "" +if (!project.hasProperty(crowdinApiKey)) ext[crowdinApiKey] = "" - apply(plugin = "com.mendhak.gradlecrowdin") - - tasks.named("crowdinUpload") { - apiKey = crowdinApiKey - projectId = "worldedit-core" - files = arrayOf( - object { - var name = "strings.json" - var source = "$projectDir/src/main/resources/lang/strings.json" - } - ) - } - - tasks.named("crowdinDownload") { - apiKey = crowdinApiKey - destination = "$projectDir/src/main/resources/lang" - projectId = "worldedit-core" - } - - tasks.named("processResources").configure { - dependsOn("crowdinDownload") - } +tasks.named("crowdinUpload") { + apiKey = "${project.property(crowdinApiKey)}" + projectId = "worldedit-core" + files = arrayOf( + object { + var name = "strings.json" + var source = "$projectDir/src/main/resources/lang/strings.json" + } + ) +} + +tasks.named("crowdinDownload") { + apiKey = "${project.property(crowdinApiKey)}" + destination = "$projectDir/src/main/resources/lang" + projectId = "worldedit-core" +} + +tasks.named("processResources").configure { + dependsOn("crowdinDownload") }