-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathbuild.gradle
118 lines (94 loc) · 3.13 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
113
114
115
116
117
118
plugins {
id 'java'
id 'maven-publish'
id 'architectury-plugin' version "${architect_plugin_version}" apply false
id 'dev.architectury.loom' version "${loom_plugin_version}" apply false
id 'com.gradleup.shadow' version "${shadow_plugin_version}" apply false
id 'xyz.jpenilla.run-paper' version "${run_task_plugin_version}" apply false
id 'xyz.jpenilla.run-waterfall' version "${run_task_plugin_version}" apply false
id 'xyz.jpenilla.run-velocity' version "${run_task_plugin_version}" apply false
}
def ENV = System.getenv()
allprojects {
apply plugin: 'maven-publish'
group = project_group
version = project_version
repositories {
mavenLocal()
maven {
name = 'ParchmentMC'
url = 'https://maven.parchmentmc.org'
}
maven {
name = 'PaperMC'
url = 'https://repo.papermc.io/repository/maven-public/'
}
maven {
name = 'Architectury'
url = 'https://maven.architectury.dev/'
}
maven {
name = 'FabricMC'
url = 'https://maven.fabricmc.net/'
}
maven {
name = 'NeoForged'
url = 'https://maven.neoforged.net/releases/'
}
maven {
name = 'Sonatype'
url = 'https://oss.sonatype.org/content/groups/public/'
}
maven {
name = 'Sonatype Snapshots'
url = 'https://oss.sonatype.org/content/repositories/snapshots'
}
maven {
name = 'Mod Menu'
url = 'https://maven.terraformersmc.com/releases'
}
maven {
name = 'Curse maven'
url = 'https://cursemaven.com'
content {
includeGroup 'curse.maven'
}
}
mavenCentral()
}
publishing {
repositories {
mavenLocal()
maven {
name = 'YuluoMaven'
def releaseUrl = 'https://maven.yuluo.dev/repository/maven-releases/'
def snapshotUrl = 'https://maven.yuluo.dev/repository/maven-snapshots/'
url = ENV.MOD_RELEASE ? releaseUrl : snapshotUrl
credentials {
username ENV.MOD_MAVEN_USER
password ENV.MOD_MAVEN_PASS
}
}
}
}
}
subprojects {
apply plugin: 'java'
base {
archivesBaseName = "catmessenger-${project.name}"
}
dependencies {
compileOnly group: 'org.projectlombok', name: 'lombok', version: '1.18.36'
annotationProcessor group: 'org.projectlombok', name: 'lombok', version: '1.18.36'
}
java {
sourceCompatibility = JavaVersion.toVersion(project.target_java_version)
targetCompatibility = JavaVersion.toVersion(project.target_java_version)
toolchain.languageVersion = JavaLanguageVersion.of(project.target_java_version)
withSourcesJar()
}
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
options.release = JavaLanguageVersion.of(project.target_java_version).asInt()
}
}