Scripts/lom/src/main/kotlin/io/gitlab/jfronny/scripts/LomExtension.kt

27 lines
642 B
Kotlin
Raw Normal View History

package io.gitlab.jfronny.scripts
2022-10-06 19:30:52 +02:00
import net.fabricmc.loom.LoomGradleExtension
import org.gradle.api.Project
import org.gradle.api.provider.Property
import java.util.*
interface LomExtension {
var yarnBuild: String?
fun yarn(yarnBuild: String) {
this.yarnBuild = Objects.requireNonNull(yarnBuild)
}
fun mojmap() {
yarnBuild = null
}
val minecraftVersion: Property<String>
val loaderVersion: Property<String>
companion object {
operator fun get(project: Project): LoomGradleExtension {
return project.extensions.getByName("lom") as LoomGradleExtension
}
}
}