From 5d5e31fad09fee007a41ef9c62e3fc361a0f4dd7 Mon Sep 17 00:00:00 2001 From: DatLag Date: Wed, 14 Aug 2024 01:00:50 +0200 Subject: [PATCH] fix copy task --- .../datlag/sekret/gradle/tasks/CopySekretNativeBinaryTask.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sekret-gradle-plugin/src/main/java/dev/datlag/sekret/gradle/tasks/CopySekretNativeBinaryTask.kt b/sekret-gradle-plugin/src/main/java/dev/datlag/sekret/gradle/tasks/CopySekretNativeBinaryTask.kt index e1201ba..9534663 100644 --- a/sekret-gradle-plugin/src/main/java/dev/datlag/sekret/gradle/tasks/CopySekretNativeBinaryTask.kt +++ b/sekret-gradle-plugin/src/main/java/dev/datlag/sekret/gradle/tasks/CopySekretNativeBinaryTask.kt @@ -131,8 +131,8 @@ abstract class CopySekretNativeBinaryTask : DefaultTask() { private fun copyFileFromTo(from: String, dest: File) { fileSystem.copy { - from(File(from)) - into(dest.mkdirsSafely()) + from(from) + into(dest.also { it.mkdirsSafely() }) exclude("**/*.h", "**/*.def") } }