Skip to content

Commit 02c6323

Browse files
fix: simplified the gradle setup
1 parent 079525b commit 02c6323

6 files changed

Lines changed: 13 additions & 17 deletions

File tree

build.gradle

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -55,18 +55,12 @@ subprojects {
5555
}
5656

5757
if (project.name != "common") {
58-
tasks.withType(JavaCompile).configureEach {
59-
if (!it.name.toLowerCase().contains("test")) {
60-
source(project(":common").sourceSets.main.allSource)
61-
}
62-
}
63-
64-
tasks.withType(Javadoc).configureEach {
65-
source(project(":common").sourceSets.main.allJava)
58+
dependencies {
59+
api project(":common")
6660
}
6761

68-
processResources {
69-
from project(":common").sourceSets.main.resources
62+
jar {
63+
from project(":common").sourceSets.main.output
7064
}
7165
}
7266

common/build.gradle

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ plugins {
44

55
loom {
66
accessWidenerPath = project(":common").file("src/main/resources/xray.accesswidener")
7+
8+
mixin {
9+
useLegacyMixinAp = false
10+
}
711
}
812

913
dependencies {

common/gradle.properties

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
fabric.loom.dontRemap=true

fabric/build.gradle

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ loom {
1818
sourceSet sourceSets.main
1919
}
2020
}
21+
22+
mixin {
23+
useLegacyMixinAp = false
24+
}
2125
}
2226

2327
dependencies {
@@ -26,8 +30,6 @@ dependencies {
2630

2731
modImplementation "net.fabricmc:fabric-loader:${project.loader_version}"
2832
modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"
29-
30-
compileOnly project(":common")
3133
}
3234

3335
repositories {

fabric/src/main/resources/xray.mixins.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"required": true,
33
"package": "pro.mikey.xray.mixins",
4-
"refmap": "advanced-xray-fabric-refmap.json",
54
"compatibilityLevel": "JAVA_17",
65
"client": [
76
"LevelMixin"

neoforge/build.gradle

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,6 @@ configurations {
3030
runtimeClasspath.extendsFrom localRuntime
3131
}
3232

33-
dependencies {
34-
compileOnly project(":common")
35-
}
36-
3733
repositories {
3834
maven {
3935
url "https://maven.neoforged.net/releases"

0 commit comments

Comments
 (0)