-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle
102 lines (81 loc) · 2.56 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
import org.apache.tools.ant.filters.ReplaceTokens
plugins {
id 'com.gradleup.shadow' version '9.0.0-beta4' apply false
}
allprojects {
group = 'by.milansky.protocol'
version = '1.1.1'
}
configure(subprojects - project(':examples')) {
apply plugin: 'java'
apply plugin: 'maven-publish'
repositories {
mavenLocal()
mavenCentral()
maven {
url = "https://repo.abelix.club/repository/public/"
}
}
dependencies {
compileOnly libs.lombok
annotationProcessor libs.lombok
testCompileOnly libs.lombok
testAnnotationProcessor libs.lombok
compileOnly libs.fastutil
compileOnly libs.netty.all
compileOnly libs.log4j.core
compileOnly libs.jetbrains.annotations
compileOnly libs.jackson.databind
compileOnly libs.gson
compileOnly libs.adventure.api
compileOnly libs.adventure.nbt
compileOnly libs.adventure.serializer.gson
compileOnly libs.adventure.serializer.legacy
compileOnly libs.adventure.serializer.gson.legacy
testImplementation libs.netty.all
testImplementation libs.log4j.core
testImplementation libs.junit.api
testRuntimeOnly libs.junit.engine
}
publishing {
repositories {
maven {
name = "milansky-repo"
url = uri("https://maven.milansky.ovh/releases")
credentials {
username = System.getenv("MILANSKY_REPO_USER")
password = System.getenv("MILANSKY_REPO_TOKEN")
}
}
}
publications {
gpr(MavenPublication) {
from(components.java)
pom {
licenses {
license {
name = 'MIT License'
url = 'https://github.com/rmilansky/minecraft-protocol-java/blob/master/LICENSE'
}
}
}
}
}
}
tasks {
register('processSource', Copy) {
from(sourceSets.main.java)
into("$buildDir/src")
inputs.property 'version', version
filter(ReplaceTokens, tokens: [version: version], beginToken: '${', endToken: '}')
}
compileJava {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
source = processSource.outputs
}
}
test {
useJUnitPlatform()
}
}