forked from NichtStudioCode/MiniatureBlocks
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
104 lines (89 loc) · 3.16 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
import java.text.SimpleDateFormat
plugins {
id 'java'
id 'maven-publish'
id 'com.github.johnrengelman.shadow' version '7.1.2'
id 'org.jetbrains.kotlin.jvm' version '1.8.0'
}
repositories {
mavenLocal()
maven {
url = uri('https://hub.spigotmc.org/nexus/content/repositories/snapshots/')
}
maven {
url = uri('https://libraries.minecraft.net/')
}
maven {
url = uri('https://repo.codemc.org/repository/maven-public')
}
maven {
url = uri('https://repo.xenondevs.xyz/releases/')
}
maven {
url = uri('https://repo.maven.apache.org/maven2/')
}
}
dependencies {
implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.7.0'
implementation 'net.lingala.zip4j:zip4j:2.11.2'
implementation 'commons-io:commons-io:2.11.0'
implementation 'org.bstats:bstats-bukkit:3.0.0'
implementation 'de.studiocode.invui:InvUI:0.10.2'
implementation 'de.studiocode.invui:ResourcePack:0.10.2'
implementation 'xyz.xenondevs:particle:1.8.3'
implementation 'me.xdrop:fuzzywuzzy:1.4.0'
testImplementation 'org.jetbrains.kotlin:kotlin-test:1.7.0'
compileOnly 'org.spigotmc:spigot-api:1.19.3-R0.1-SNAPSHOT'
compileOnly 'com.mojang:brigadier:1.0.18'
compileOnly 'com.mojang:authlib:1.5.21'
}
group = 'de.studiocode'
def pluginVersion = '0.16'
version = pluginVersion
description = 'MiniatureBlocks'
java.sourceCompatibility = JavaVersion.VERSION_1_8
ext {
shadePath = 'de.studiocode.miniatureblocks.lib'
}
publishing {
publications {
maven(MavenPublication) {
from(components.java)
}
}
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
artifacts {
archives shadowJar
}
processResources {
filesMatching(['plugin.yml']) {
expand version: pluginVersion
}
}
shadowJar {
relocate("org.bstats", "${shadePath}.org.bstats")
relocate("de.studiocode.invui", "${shadePath}.de.studiocode.invui")
relocate("de.studiocode.inventoryaccess", "${shadePath}.de.studiocode.inventoryaccess")
relocate("xyz.xenondevs.particle", "${shadePath}.xyz.xenondevs.particle")
relocate("kotlin", "${shadePath}.kotlin")
relocate("org.intellij.lang.annotations", "${shadePath}.org.intellij.lang.annotations")
relocate("org.jetbrains.annotations", "${shadePath}.org.jetbrains.annotations")
relocate("org.apache.commons.io", "${shadePath}.org.apache.commons.io")
relocate("net.lingala.zip4j", "${shadePath}.net.lingala.zip4j")
relocate("me.xdrop", "${shadePath}.me.xdrop")
manifest {
attributes(
'Built-By': System.properties['user.name'],
'Version': pluginVersion,
'Build-Timestamp': new SimpleDateFormat("yyyy-MM-dd' 'HH:mm:ss.SSSZ").format(new Date()),
'Created-By': "Gradle ${gradle.gradleVersion}",
'Build-Jdk': "${System.properties['java.version']} " +
"(${System.properties['java.vendor']} ${System.properties['java.vm.version']})",
'Build-OS': "${System.properties['os.name']} ${System.properties['os.arch']} " +
"${System.properties['os.version']}"
)
}
}