forked from Platymemo/alaskanativecraft
-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle
96 lines (80 loc) · 2.84 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
plugins {
id "com.matthewprenger.cursegradle" version "1.4.0"
id "com.modrinth.minotaur" version "1.2.1"
id 'maven-publish'
alias libs.plugins.quilt.loom
}
archivesBaseName = project.archives_base_name
version = project.mod_version
group = project.maven_group
repositories {
maven {
url = "https://maven.fabricmc.net"
}
maven {
url = "https://maven.terraformersmc.com/releases"
}
maven {
url = "https://maven.shedaniel.me"
}
}
dependencies {
// To change the versions see the gradle.properties file
minecraft libs.minecraft
mappings loom.layered {
addLayer quiltMappings.mappings("org.quiltmc:quilt-mappings:${libs.versions.quilt.mappings.get()}:v2")
// officialMojangMappings() // Uncomment if you want to use Mojang mappings as your primary mappings, falling back on QM for parameters and Javadocs
}
modImplementation libs.quilt.loader
modImplementation libs.quilted.fabric.api
// Mod Menu integration
modImplementation "com.terraformersmc:modmenu:${project.modmenu_version}"
// REI integration
modImplementation "me.shedaniel:RoughlyEnoughItems-fabric:${project.rei_version}"
// We have to manually override the version of Architectury used by REI to run on Quilt
modLocalRuntime "dev.architectury:architectury-fabric:${project.architectury_override_version}"
// ClothConfig
modApi("me.shedaniel.cloth:cloth-config-fabric:${project.clothconfig_version}") {
exclude(group: "net.fabricmc.fabric-api")
}
// PSA: Some older mods, compiled on Loom 0.2.1, might have outdated Maven POMs.
// You may need to force-disable transitiveness on them.
}
loom {
accessWidenerPath = file("src/main/resources/alaskanativecraft.accesswidener")
}
processResources {
inputs.property "version", project.mod_version
filesMatching('quilt.mod.json') {
expand "version": project.mod_version
}
}
tasks.withType(JavaCompile).configureEach {
it.options.encoding = "UTF-8"
// Minecraft 1.18 (1.18-pre2) upwards uses Java 17.
it.options.release = 17
}
java {
// Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task
// if it is present.
// If you remove this line, sources will not be generated.
withSourcesJar()
}
jar {
from("LICENSE") {
rename { "${it}_${project.archivesBaseName}" }
}
}
// configure the maven publication
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
}
}
// Select the repositories you want to publish to
// To publish to maven local, no extra repositories are necessary. Just use the task `publishToMavenLocal`.
repositories {
// See https://docs.gradle.org/current/userguide/publishing_maven.html for information on how to set up publishing.
}
}