mirror of
https://github.com/Xiao-MoMi/Custom-Crops.git
synced 2025-12-25 18:09:28 +00:00
90 lines
3.9 KiB
Groovy
90 lines
3.9 KiB
Groovy
plugins {
|
|
id 'java'
|
|
id 'com.github.johnrengelman.shadow' version '7.1.2'
|
|
}
|
|
|
|
group = 'net.momirealms'
|
|
version = '2.2.6-hotfix'
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
maven {name = 'papermc-repo'; url = 'https://papermc.io/repo/repository/maven-public/'}
|
|
maven {name = 'sonatype'; url = 'https://oss.sonatype.org/content/groups/public/'}
|
|
maven {name = "sonatype-oss-snapshots1"; url = "https://s01.oss.sonatype.org/content/repositories/snapshots/"}
|
|
maven {name = "dmulloy2-repo"; url = "https://repo.dmulloy2.net/repository/public/"}
|
|
maven {name = "clip-repo"; url = 'https://repo.extendedclip.com/content/repositories/placeholderapi/'}
|
|
maven {name = "NBT-API"; url = "https://repo.codemc.org/repository/maven-public/"}
|
|
maven {name = "sk89q-repo"; url = "https://maven.enginehub.org/repo/"}
|
|
maven {name = "Lumine Releases"; url = "https://mvn.lumine.io/repository/maven-public"}
|
|
maven {name = "jitpack-repo"; url = "https://jitpack.io"}
|
|
maven {name = 'glaremasters repo'; url = 'https://repo.glaremasters.me/repository/towny/'}
|
|
maven {name = 'superior skyblock repo'; url = 'https://repo.bg-software.com/repository/api/'}
|
|
maven {name = 'bg-repo'; url = 'https://repo.bg-software.com/repository/api/'}
|
|
maven {name = "Lumine Releases"; url = "https://mvn.lumine.io/repository/maven-public"}
|
|
}
|
|
|
|
dependencies {
|
|
compileOnly ('dev.dejvokep:boosted-yaml:1.3')
|
|
compileOnly ('com.github.Archy-X:AureliumSkills:Beta1.3.6')
|
|
compileOnly ('commons-io:commons-io:2.11.0')
|
|
compileOnly ('com.github.angeschossen:LandsAPI:6.26.18')
|
|
compileOnly ('com.github.TechFortress:GriefPrevention:16.18')
|
|
compileOnly ('io.papermc.paper:paper-api:1.17.1-R0.1-SNAPSHOT')
|
|
compileOnly ('me.clip:placeholderapi:2.11.2')
|
|
compileOnly ('com.sk89q.worldguard:worldguard-bukkit:7.0.7')
|
|
compileOnly ('com.github.LoneDev6:api-itemsadder:3.2.3-r8')
|
|
compileOnly ('io.lumine:Mythic-Dist:5.0.3-SNAPSHOT')
|
|
compileOnly ('com.palmergames.bukkit.towny:towny:0.98.2.0')
|
|
compileOnly ('com.willfp:EcoSkills:1.72.0')
|
|
compileOnly ('com.willfp:eco:6.38.3')
|
|
compileOnly ('com.bgsoftware:SuperiorSkyblockAPI:2022.9')
|
|
compileOnly ('com.github.Zrips:Jobs:4.17.2')
|
|
compileOnly fileTree(dir:'libs',includes:['*.jar'])
|
|
implementation ('net.kyori:adventure-api:4.12.0')
|
|
implementation ('net.kyori:adventure-platform-bukkit:4.2.0')
|
|
implementation ('net.kyori:adventure-text-minimessage:4.12.0')
|
|
implementation ("de.tr7zw:item-nbt-api:2.11.1")
|
|
implementation ("org.bstats:bstats-bukkit:3.0.0")
|
|
implementation fileTree(dir:'libs',includes:['BiomeAPI.jar'])
|
|
}
|
|
|
|
def targetJavaVersion = 17
|
|
java {
|
|
def javaVersion = JavaVersion.toVersion(targetJavaVersion)
|
|
sourceCompatibility = javaVersion
|
|
targetCompatibility = javaVersion
|
|
if (JavaVersion.current() < javaVersion) {
|
|
toolchain.languageVersion = JavaLanguageVersion.of(targetJavaVersion)
|
|
}
|
|
}
|
|
|
|
tasks.withType(JavaCompile).configureEach {
|
|
if (targetJavaVersion >= 10 || JavaVersion.current().isJava10Compatible()) {
|
|
options.release = targetJavaVersion
|
|
}
|
|
}
|
|
|
|
processResources {
|
|
def props = [version: version]
|
|
inputs.properties props
|
|
filteringCharset 'UTF-8'
|
|
filesMatching('plugin.yml') {
|
|
expand props
|
|
}
|
|
}
|
|
|
|
tasks.withType(JavaCompile) {
|
|
options.encoding = "UTF-8"
|
|
}
|
|
|
|
shadowJar {
|
|
relocate ('de.tr7zw', 'net.momirealms.customcrops.libs.de.tr7zw')
|
|
relocate ('net.kyori', 'net.momirealms.customcrops.libs.net.kyori')
|
|
relocate ('org.bstats', 'net.momirealms.customcrops.libs.org.bstats')
|
|
relocate 'net.momirealms.biomeapi', 'net.momirealms.customcrops.libs.net.momirealms.biomeapi'
|
|
}
|
|
|
|
tasks.register("delete", Delete).get().delete("build/libs/"+project.name+"-"+project.version+".jar")
|
|
tasks.named("build").get().dependsOn("shadowJar").finalizedBy("delete").doLast {
|
|
println("Deleting: "+ "build/libs/"+project.name+"-"+project.version+".jar")
|
|
} |