1- import dev.kordex.gradle.plugins.kordex.DataCollection
21import org.jetbrains.kotlin.gradle.dsl.JvmTarget
32import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
43
54plugins {
65 id(" fabric-loom" ) version " 1.10-SNAPSHOT"
76 id(" maven-publish" )
87 id(" org.jetbrains.kotlin.jvm" ) version " 2.1.21"
9- id(" dev.kordex.gradle.kordex " ) version " 1.6.1 "
8+ id(" com.gradleup.shadow " ) version " 9.0.0-beta15 "
109}
1110
1211version = property(" mod_version" ).toString()
@@ -27,6 +26,20 @@ repositories {
2726 maven(" https://maven.enjarai.dev/releases" )
2827 maven(" https://maven.nucleoid.xyz" )
2928 maven(" https://api.modrinth.com/maven" )
29+ maven {
30+ name = " KordEx (Releases)"
31+ url = uri(" https://repo.kordex.dev/releases" )
32+ }
33+
34+ maven {
35+ name = " KordEx (Snapshots)"
36+ url = uri(" https://repo.kordex.dev/snapshots" )
37+ }
38+
39+ maven {
40+ name = " Kord (Snapshots)"
41+ url = uri(" https://repo.kord.dev/snapshots/" )
42+ }
3043}
3144
3245loom {
@@ -40,8 +53,10 @@ loom {
4053
4154}
4255
56+ val kordexVersion: String = property(" kordex_version" ) as String
57+
4358dependencies {
44- minecraft(" com.mojang:minecraft:${property(" minecraft_version" )} " )
59+ minecraft(" com.mojang:minecraft:${property(" minecraft_version" )} " ) {}
4560 mappings(" net.fabricmc:yarn:${property(" yarn_mappings" )} :v2" )
4661 modImplementation(" net.fabricmc:fabric-loader:${property(" loader_version" )} " )
4762
@@ -54,16 +69,11 @@ dependencies {
5469 // Monkey Utils
5570 modImplementation(" maven.modrinth:uApL7Qhc:${property(" monkey_utils_version" )} " )
5671
57-
72+ // Fabric Permissions API
5873 include(modImplementation(" me.lucko:fabric-permissions-api:0.3.1" )!! )
59- }
6074
61- kordEx {
62- jvmTarget = 21
63- bot {
64- dataCollection(DataCollection .Standard )
65- mainClass = " io.github.arkosammy12.compsmpdiscordbot.CompSMPDiscordBot"
66- }
75+ // Kordex
76+ include(implementation(" dev.kordex:kord-extensions:${kordexVersion} " )!! )
6777}
6878
6979tasks.processResources {
@@ -84,6 +94,12 @@ tasks.withType<KotlinCompile>().configureEach {
8494 }
8595}
8696
97+ tasks.shadowJar {
98+ isZip64 = true
99+ exclude(" net/fabricmc/language/kotlin/**" )
100+ exclude(" fabric-language-kotlin-*.jar" )
101+ }
102+
87103java {
88104 // Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task
89105 // if it is present.
0 commit comments