-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
58 lines (53 loc) · 1.9 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
plugins {
id 'com.github.johnrengelman.shadow' version '7.0.0' apply false
id 'com.github.gmazzo.buildconfig' version '3.1.0' apply false
}
group = 'top.mrxiaom'
version = '1.0.35'
subprojects {
apply plugin: 'java'
group = rootProject.group
version = rootProject.version
repositories {
mavenLocal()
mavenCentral()
maven { url 'https://maven.fastmirror.net/repositories/minecraft' }
maven { url "https://mvn.lumine.io/repository/maven/" }
maven { url = 'https://repo.codemc.io/repository/maven-public/' }
maven { name 'Aikar'; url 'https://repo.aikar.co/content/groups/aikar/' }
maven { url "https://repo.papermc.io/repository/maven-public/" }
maven {
name = 'spigotmc-repo'
url = 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/'
}
maven { url = "https://repo.viaversion.com/" }
maven { url = 'https://repo.extendedclip.com/content/repositories/placeholderapi/' }
maven { url = 'https://jitpack.io' }
maven { url = 'https://ci.nyaacat.com/maven/' }
maven {
name = 'sonatype'
url = 'https://oss.sonatype.org/content/groups/public/'
}
}
def targetJavaVersion = 11
java {
def javaVersion = JavaVersion.toVersion(targetJavaVersion)
if (JavaVersion.current() < javaVersion) {
toolchain.languageVersion = JavaLanguageVersion.of(targetJavaVersion)
}
}
jar {
archiveBaseName = rootProject.name + "-" + project.name
}
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
options.release.set(targetJavaVersion)
}
processResources {
duplicatesStrategy = DuplicatesStrategy.INCLUDE
from(sourceSets.main.resources.srcDirs) {
expand('version': version)
include 'plugin.yml'
}
}
}