mirror of
https://github.com/mamoe/mirai.git
synced 2025-01-11 02:50:15 +08:00
Fix gradle tasks
This commit is contained in:
parent
3a5d95aee3
commit
b36ddf29e2
@ -2,17 +2,24 @@ package net.mamoe.mirai.console.gradle
|
|||||||
|
|
||||||
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
|
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
|
||||||
import org.gradle.api.tasks.CacheableTask
|
import org.gradle.api.tasks.CacheableTask
|
||||||
|
import org.gradle.api.tasks.Internal
|
||||||
|
import org.gradle.api.tasks.OutputFile
|
||||||
import org.jetbrains.kotlin.gradle.plugin.KotlinTarget
|
import org.jetbrains.kotlin.gradle.plugin.KotlinTarget
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
||||||
@CacheableTask
|
@CacheableTask
|
||||||
public open class BuildMiraiPluginTask : ShadowJar() {
|
public open class BuildMiraiPluginTask : ShadowJar() {
|
||||||
internal var targetField: KotlinTarget? = null
|
@Internal
|
||||||
|
public var targetField: KotlinTarget? = null
|
||||||
|
|
||||||
public val target: KotlinTarget get() = targetField!!
|
@get:Internal
|
||||||
|
public val target: KotlinTarget
|
||||||
|
get() = targetField!!
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ShadowJar 打包结果
|
* ShadowJar 打包结果
|
||||||
*/
|
*/
|
||||||
public val output: File get() = outputs.files.singleFile
|
@get:OutputFile
|
||||||
|
public val output: File
|
||||||
|
get() = outputs.files.singleFile
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user