Skip to content

Commit 0837451

Browse files
committed
Loom 1.9, Gradle 8.11.1 and run datagen from client
1 parent 0e5659a commit 0837451

File tree

4 files changed

+10
-6
lines changed

4 files changed

+10
-6
lines changed

scripts/src/lib/Versions.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ fabric_version={apiVersion}
8282

8383
<h2>Loom</h2>
8484

85-
<p>The recommended loom version is <strong>1.8-SNAPSHOT</strong>. This is usually defined near the top of your build.gradle file.</p>
85+
<p>The recommended loom version is <strong>1.9-SNAPSHOT</strong>. This is usually defined near the top of your build.gradle file.</p>
8686

8787
<style>
8888
.copy-code {

scripts/src/lib/template/modentrypoint.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ async function generateJavaEntrypoint(writer: TemplateWriter, options: ClassOpti
6969
}
7070

7171
if (options.dataEntrypoint) {
72-
await writer.write(`src/main/java/${options.path}DataGenerator.java`, renderTemplate(javaEntrypointDataGeneratorTemplate, {...options, className: options.className + "DataGenerator"}));
72+
const sourceSet = options.clientEntrypoint ? "client" : "main";
73+
await writer.write(`src/${sourceSet}/java/${options.path}DataGenerator.java`, renderTemplate(javaEntrypointDataGeneratorTemplate, {...options, className: options.className + "DataGenerator"}));
7374

7475
entrypoints = {
7576
...entrypoints,
@@ -109,7 +110,8 @@ async function generateKotlinEntrypoint(writer: TemplateWriter, options: ClassOp
109110
}
110111

111112
if (options.dataEntrypoint) {
112-
await writer.write(`src/main/kotlin/${options.path}DataGenerator.kt`, renderTemplate(kotlinEntrypointDataGeneratorTemplate, {...options, className: options.className + "DataGenerator"}))
113+
const sourceSet = options.clientEntrypoint ? "client" : "main";
114+
await writer.write(`src/${sourceSet}/kotlin/${options.path}DataGenerator.kt`, renderTemplate(kotlinEntrypointDataGeneratorTemplate, {...options, className: options.className + "DataGenerator"}))
113115

114116
entrypoints = {
115117
...entrypoints,

scripts/src/lib/template/templates/gradle/groovy/build.gradle.eta

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
plugins {
2-
id 'fabric-loom' version '1.8-SNAPSHOT'
2+
id 'fabric-loom' version '1.9-SNAPSHOT'
33
id 'maven-publish'
44
<%_ if (it.kotlin) { %>
55
id "org.jetbrains.kotlin.jvm" version "<%= it.kotlin.kotlinVersion %>"
@@ -34,7 +34,9 @@ loom {
3434
}
3535
<% } %><% if (it.dataGeneration) { %>
3636
fabricApi {
37-
configureDataGeneration()
37+
configureDataGeneration {
38+
client = true
39+
}
3840
}
3941
<% } %>
4042
dependencies {

scripts/src/lib/template/templates/gradle/wrapper/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

0 commit comments

Comments
 (0)