From f739270018ea248b0041b986462f42ad7ae44fed Mon Sep 17 00:00:00 2001 From: Goooler Date: Thu, 24 Aug 2023 16:01:50 +0800 Subject: [PATCH] Migrate deprecated buildDir --- diffuse/build.gradle | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/diffuse/build.gradle b/diffuse/build.gradle index 37c00f7e..5be50c0f 100644 --- a/diffuse/build.gradle +++ b/diffuse/build.gradle @@ -53,7 +53,7 @@ def fatJarProvider = tasks.register('fatJar', Jar) { task -> } } -def r8File = new File("$buildDir/libs/$archivesBaseName-$version-r8.jar") +def r8File = layout.buildDirectory.file("libs/$archivesBaseName-$version-r8.jar").get().asFile def rulesFile = project.file("src/main/rules.txt") def r8JarProvider = tasks.register('r8Jar', JavaExec) { task -> def fatJar = fatJarProvider.get() @@ -75,7 +75,7 @@ def r8JarProvider = tasks.register('r8Jar', JavaExec) { task -> ] } -def binaryFile = new File(buildDir, "libs/$archivesBaseName-$version-binary.jar") +def binaryFile = layout.buildDirectory.file("libs/$archivesBaseName-$version-binary.jar").get().asFile def binaryJar = tasks.register('binaryDiffuseJar') { task -> task.dependsOn(r8JarProvider)