[zipPlugin task] Remove deprecated calls and allow default destination path for empty pluginZipPath argument. (#3254)

Co-authored-by: Alanna Tempest <atem@fb.com>

Co-authored-by: Alanna Tempest <atem@fb.com>
This commit is contained in:
Irene Dea
2020-04-08 04:54:08 -07:00
committed by GitHub
parent 5d34b156bf
commit 419d6d0015
+3 -6
View File
@@ -800,18 +800,15 @@ val zipPlugin by task<Zip> {
} }
val destPath = project.findProperty("pluginZipPath") as String? val destPath = project.findProperty("pluginZipPath") as String?
val dest = File(destPath ?: "$buildDir/kotlin-plugin.zip") val dest = File(destPath ?: "$buildDir/kotlin-plugin.zip")
destinationDir = dest.parentFile destinationDirectory.set(dest.parentFile)
archiveName = dest.name archiveFileName.set(dest.name)
doFirst {
if (destPath == null) throw GradleException("Specify target zip path with 'pluginZipPath' property")
}
from(src) from(src)
into("Kotlin") into("Kotlin")
setExecutablePermissions() setExecutablePermissions()
doLast { doLast {
logger.lifecycle("Plugin artifacts packed to $archivePath") logger.lifecycle("Plugin artifacts packed to $archiveFile")
} }
} }