-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle.kts
83 lines (68 loc) · 2.12 KB
/
build.gradle.kts
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
plugins {
application
id("com.github.johnrengelman.shadow") version "8.1.1"
}
group = "cc.tweaked"
version = "1.0"
val modVersion = "1.114.2"
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
}
}
repositories {
mavenCentral()
exclusiveContent {
forRepository {
maven("https://maven.squiddev.cc")
}
filter {
includeGroup("cc.tweaked")
}
}
}
dependencies {
implementation("cc.tweaked:cc-tweaked-1.20.1-core:$modVersion")
implementation("org.slf4j:slf4j-api:2.0.13")
implementation("com.google.guava:guava:31.1-jre")
// Instrumentation
val otVersion = "1.39.0"
implementation(platform("io.opentelemetry:opentelemetry-bom:$otVersion"))
implementation("io.opentelemetry:opentelemetry-api")
implementation("io.opentelemetry:opentelemetry-api")
implementation("io.opentelemetry:opentelemetry-sdk")
implementation("io.opentelemetry:opentelemetry-exporter-otlp")
implementation("io.opentelemetry:opentelemetry-extension-trace-propagators")
implementation("io.opentelemetry.semconv:opentelemetry-semconv:1.25.0-alpha")
runtimeOnly("io.opentelemetry.instrumentation:opentelemetry-logback-mdc-1.0:2.4.0-alpha")
// Logging
runtimeOnly("ch.qos.logback:logback-core:1.5.6")
runtimeOnly("ch.qos.logback:logback-classic:1.5.6")
}
application {
mainClass.set("cc.tweaked.eval.Main")
}
tasks.named<Jar>("jar") {
manifest {
attributes(
mapOf(
"Implementation-Title" to "eval.tweaked.cc",
"Implementation-Version" to modVersion,
"Implementation-Vendor" to "SquidDev",
)
)
}
}
tasks.named<com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar>("shadowJar") {
mergeServiceFiles()
minimize() {
exclude(dependency("ch.qos.logback:.*:.*"))
exclude(dependency("io.opentelemetry.*:.*:.*"))
}
}
tasks.withType(AbstractArchiveTask::class.java).configureEach {
isPreserveFileTimestamps = false
isReproducibleFileOrder = true
filePermissions {}
dirPermissions {}
}