Skip to content

Commit 4273907

Browse files
committed
build updates
1 parent b501d50 commit 4273907

File tree

5 files changed

+11
-13
lines changed

5 files changed

+11
-13
lines changed

build.gradle.kts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
plugins {
22
`build-logic`
3+
alias(libs.plugins.shadow)
34
}
45

56
group = "xyz.jpenilla"
@@ -12,9 +13,7 @@ repositories {
1213

1314
dependencies {
1415
compileOnlyApi(libs.checker.qual)
15-
implementation(libs.mapping.io) {
16-
exclude("org.ow2.asm")
17-
}
16+
implementation(libs.mapping.io)
1817

1918
// testing dependencies
2019
testImplementation(libs.memoryMeasurer)
@@ -23,3 +22,7 @@ dependencies {
2322
testImplementation(libs.junit.jupiter.api)
2423
testRuntimeOnly(libs.junit.jupiter.engine)
2524
}
25+
26+
tasks.shadowJar {
27+
relocate("net.fabricmc.mappingio", "xyz.jpenilla.reflectionremapper.internal.lib.mappingio")
28+
}

buildSrc/src/main/kotlin/ExtractMappings.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
import org.gradle.api.DefaultTask
22
import org.gradle.api.file.RegularFileProperty
3-
import org.gradle.api.tasks.CacheableTask
43
import org.gradle.api.tasks.InputFile
54
import org.gradle.api.tasks.OutputFile
65
import org.gradle.api.tasks.PathSensitive
76
import org.gradle.api.tasks.PathSensitivity
87
import org.gradle.api.tasks.TaskAction
8+
import org.gradle.work.DisableCachingByDefault
99
import java.net.URI
1010
import java.nio.file.FileSystems
1111
import java.nio.file.Files
1212

13-
@CacheableTask
13+
@DisableCachingByDefault(because = "Not worth caching")
1414
abstract class ExtractMappings : DefaultTask() {
1515
@get:InputFile
1616
@get:PathSensitive(PathSensitivity.NONE)

buildSrc/src/main/kotlin/base-conventions.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ tasks {
3131
)
3232
}
3333
}
34-
withType<Jar> {
34+
withType<Jar>().configureEach {
3535
from(rootProject.file("LICENSE")) {
3636
rename("LICENSE", "META-INF/LICENSE_${rootProject.name}")
3737
}

buildSrc/src/main/kotlin/build-logic.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ tasks {
1919
processTestResources {
2020
dependsOn(extractMappings)
2121
}
22-
withType<Test> {
22+
withType<Test>().configureEach {
2323
if (!name.contains("Java8")) {
2424
inputs.files(memoryMeasurer)
2525
doFirst {

buildSrc/src/main/kotlin/publishing-conventions.gradle.kts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,5 @@ indra {
1717
}
1818
}
1919
}
20-
}
21-
22-
signing {
23-
val signingKey: String? by project
24-
val signingPassword: String? by project
25-
useInMemoryPgpKeys(signingKey, signingPassword)
20+
signWithKeyFromProperties("signingKey", "signingPassword")
2621
}

0 commit comments

Comments
 (0)