-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
54 lines (48 loc) · 1.61 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
subprojects
{
apply plugin: "java"
java.toolchain.languageVersion = JavaLanguageVersion.of(java_version)
base
{
archivesName = "${mod_jar_name}-${project.name.toUpperCase()}-${minecraft_version}"
}
processResources
{
var replaceProperties =
[
"mod_name" : mod_name,
"mod_jar_name" : mod_jar_name,
"mod_id" : mod_id,
"mod_group" : mod_group,
"mod_author" : mod_author,
"version" : version,
"license" : license,
"homepage" : homepage,
"source_url" : source_url,
"issue_tracker" : issue_tracker,
"mod_description" : mod_description,
"minecraft_version" : minecraft_version,
"java_version" : java_version,
"version_range_fabric" : version_range_fabric,
"version_range_neoforge" : version_range_neoforge,
"fabric_loader_version" : fabric_loader_version,
"fabric_api_version" : fabric_api_version,
"neoforge_version" : neoforge_version,
]
filesMatching(["pack.mcmeta", "fabric.mod.json", "META-INF/neoforge.mods.toml", "*.mixins.json"])
{
expand replaceProperties
}
inputs.properties replaceProperties
}
tasks.withType(JavaCompile).configureEach { it.options.encoding = "UTF-8" }
if (project.name != "common")
{
dependencies
{
compileOnly project(":common")
}
processResources { from project(":common").sourceSets.main.resources }
tasks.named("compileJava", JavaCompile) { source project(":common").sourceSets.main.allSource }
}
}