Added: entitylib.shadow-conventions.gradle.kts

Renamed: entitylib.java-conventions.gradle.kts -> entitylib.library-conventions.gradle.kts
Switched: johnrengelman's shadow to googler's shadow fork
This commit is contained in:
Bram 2024-07-07 19:08:21 +02:00
parent 6321195956
commit 0a1e95a17d
No known key found for this signature in database
GPG key ID: 13E608068F40E3CC
15 changed files with 55 additions and 23 deletions

View file

@ -1,6 +1,6 @@
plugins {
entitylib.`java-conventions`
`java-library`
entitylib.`library-conventions`
entitylib.`shadow-conventions`
`el-version`
}

View file

@ -1,6 +1,5 @@
plugins {
entitylib.`java-conventions`
id("java-library")
entitylib.`library-conventions`
}
group = "me.tofaa.entitylib"

View file

@ -9,5 +9,10 @@ kotlin {
}
repositories {
gradlePluginPortal()
mavenCentral()
}
dependencies {
implementation(libs.shadow)
}

View file

@ -0,0 +1,5 @@
[versions]
shadow = "8.1.8"
[libraries]
shadow = { group = "io.github.goooler.shadow", name = "shadow-gradle-plugin", version.ref = "shadow" }

View file

@ -0,0 +1,7 @@
dependencyResolutionManagement {
versionCatalogs {
create("libs") {
from(files("libs.versions.toml"))
}
}
}

View file

@ -1,5 +1,5 @@
plugins {
java
`java-library`
`maven-publish`
}
@ -32,8 +32,6 @@ tasks {
withType<JavaCompile> {
options.encoding = Charsets.UTF_8.name()
// Set the release flag. This configures what version bytecode the compiler will emit, as well as what JDK APIs are usable.
// See https://openjdk.java.net/jeps/247 for more information.
options.release = 8
}

View file

@ -0,0 +1,19 @@
plugins {
java
io.github.goooler.shadow
}
tasks {
shadowJar {
archiveFileName = "EntityLib-${project.name}-${project.version}.jar"
archiveClassifier = null
mergeServiceFiles()
}
assemble {
dependsOn(shadowJar)
}
}
configurations.implementation.get().extendsFrom(configurations.shadow.get())

View file

@ -1,5 +1,6 @@
plugins {
entitylib.`java-conventions`
entitylib.`library-conventions`
entitylib.`shadow-conventions`
}
dependencies {

View file

@ -1,6 +1,6 @@
plugins {
entitylib.`java-conventions`
`java-library`
entitylib.`library-conventions`
entitylib.`shadow-conventions`
}
dependencies {

View file

@ -6,7 +6,6 @@ packetevents = "2.4.1-SNAPSHOT"
paper = "1.21-R0.1-SNAPSHOT"
velocity = "3.3.0-SNAPSHOT"
run-paper = "2.3.0"
shadow = "8.1.1"
javapoet = "1.13.0"
[libraries]
@ -30,4 +29,3 @@ adventure = ["adventure-api", "adventure-text-serializer-gson", "adventure-text-
[plugins]
run-paper = { id = "xyz.jpenilla.run-paper", version.ref = "run-paper" }
run-velocity = { id = "xyz.jpenilla.run-velocity", version.ref = "run-paper" }
shadow = { id = "com.github.johnrengelman.shadow", version.ref = "shadow" }

View file

@ -1,6 +1,6 @@
plugins {
entitylib.`java-conventions`
`java-library`
entitylib.`library-conventions`
entitylib.`shadow-conventions`
}
repositories {

View file

@ -1,6 +1,6 @@
plugins {
entitylib.`java-conventions`
`java-library`
entitylib.`library-conventions`
entitylib.`shadow-conventions`
}
repositories {

View file

@ -1,6 +1,6 @@
plugins {
entitylib.`java-conventions`
`java-library`
entitylib.`library-conventions`
entitylib.`shadow-conventions`
}
dependencies {

View file

@ -1,6 +1,6 @@
plugins {
entitylib.`java-conventions`
`java-library`
entitylib.`library-conventions`
entitylib.`shadow-conventions`
}
repositories {

View file

@ -1,6 +1,6 @@
plugins {
entitylib.`java-conventions`
alias(libs.plugins.shadow)
entitylib.`library-conventions`
entitylib.`shadow-conventions`
alias(libs.plugins.run.paper)
}