-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle
112 lines (93 loc) · 2.89 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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
import org.gradle.util.GradleVersion
import java.time.Instant
plugins {
id "fabric-loom" version "0.12.5"
id "io.github.juuxel.loom-quiltflower" version "1.6.1"
id "net.nemerosa.versioning" version "2.15.1"
}
group = "selic.re"
version = "1.1.0"
java {
withSourcesJar()
}
loom {
mixin {
defaultRefmapName = "mixins/discord-bridge/refmap.json"
}
runs {
configureEach {
property "mixin.debug", "true"
property "mixin.debug.export.decompile", "false"
property "mixin.debug.verbose", "true"
property "mixin.dumpTargetOnFailure", "true"
property "mixin.checks", "true"
property "mixin.hotSwap", "true"
}
}
}
repositories {
mavenCentral()
maven {
url = "https://m2.dv8tion.net/releases"
content {
includeGroup "net.dv8tion"
}
}
}
configurations {
transitiveInclude
}
dependencies {
minecraft "com.mojang:minecraft:1.18.2"
mappings "net.fabricmc:yarn:1.18.2+build.2:v2"
modImplementation "net.fabricmc:fabric-loader:0.13.3"
modImplementation include(fabricApi.module("fabric-api-base", "0.48.0+1.18.2"))
modImplementation include(fabricApi.module("fabric-lifecycle-events-v1", "0.48.0+1.18.2"))
implementation(transitiveInclude("net.dv8tion:JDA:5.0.0-alpha.9")) {
exclude module: "opus-java"
}
implementation transitiveInclude("club.minnced:discord-webhooks:0.8.0")
project.configurations.transitiveInclude {
def includer = { self, Set<ResolvedDependency> dependencies ->
dependencies.forEach {
include("${it.moduleGroup}:${it.moduleName}:${it.moduleVersion}")
self(self, it.children)
}
}
includer(includer, resolvedConfiguration.firstLevelModuleDependencies)
}
testImplementation "com.google.truth:truth:1.1.3"
}
compileJava {
options.with {
it.release.set(17)
it.fork = true
it.deprecation = true
it.encoding = "UTF-8"
it.compilerArgs.addAll(["-Xlint:all", "-parameters"])
}
}
processResources {
filesMatching("/fabric.mod.json") {
expand("version": project.version)
}
}
jar {
from("/LICENSE")
manifest.attributes(
"Build-Timestamp": Instant.now(),
"Build-Revision": versioning.info.commit,
"Build-Jvm": "" +
"${System.getProperty("java.version")} (" +
"${System.getProperty("java.vm.vendor")} " +
"${System.getProperty("java.vm.version")})",
"Built-By": GradleVersion.current(),
"Implementation-Title": project.name,
"Implementation-Version": project.version,
"Implementation-Vendor": project.group,
"Specification-Title": project.name,
"Specification-Version": "1.0.0",
"Specification-Vendor": project.group,
"Sealed": "true"
)
}