-
Notifications
You must be signed in to change notification settings - Fork 13
/
build.gradle
102 lines (86 loc) · 3.45 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
plugins {
id 'java'
id 'maven-publish'
id 'com.github.johnrengelman.shadow' version '8.1.1'
}
tasks.compileJava.options.encoding = 'UTF-8'
tasks.compileJava.sourceCompatibility = JavaVersion.VERSION_1_8
group = 'net.leonardo_dgs'
version = '1.7.8'
description = 'Create cool interactive books!'
def mainPackage = 'net.leonardo_dgs.interactivebooks'
repositories {
mavenCentral()
maven { url 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/' }
maven { url 'https://repo.extendedclip.com/content/repositories/placeholderapi/' }
maven { url 'https://repo.codemc.org/repository/maven-public/' }
maven { url 'https://repo.aikar.co/content/groups/aikar/' }
maven { url 'https://jitpack.io/' }
}
dependencies {
compileOnly 'org.spigotmc:spigot-api:1.20.3-R0.1-SNAPSHOT'
compileOnly 'net.md-5:bungeecord-chat:1.21-R0.1-SNAPSHOT'
compileOnly 'me.clip:placeholderapi:2.11.6'
compileOnly 'org.projectlombok:lombok:1.18.34'
annotationProcessor 'org.projectlombok:lombok:1.18.34'
implementation 'de.tr7zw:item-nbt-api:2.14.0'
implementation 'net.kyori:adventure-text-minimessage:4.17.0'
implementation 'net.kyori:adventure-platform-bukkit:4.3.4'
implementation 'org.bstats:bstats-bukkit:3.0.2'
implementation 'co.aikar:acf-paper:0.5.1-SNAPSHOT'
implementation 'com.github.Simplix-Softworks:SimplixStorage:3.2.7'
}
tasks.shadowJar {
archiveBaseName.set(project.name)
archiveClassifier.set('')
archiveVersion.set('')
minimize()
relocate 'de.tr7zw.changeme.nbtapi', mainPackage + '.lib.nbtapi'
relocate 'net.kyori.adventure', mainPackage + '.lib.adventure'
relocate 'net.kyori.examination', mainPackage + '.lib.examination'
relocate 'net.kyori.option', mainPackage + '.lib.option'
relocate 'co.aikar.commands', mainPackage + '.lib.acf'
relocate 'co.aikar.locales', mainPackage + '.lib.locales'
relocate 'de.leonhard.storage', mainPackage + '.lib.simplixstorage'
relocate 'org.intellij', mainPackage + '.lib.intellij'
relocate 'org.jetbrains', mainPackage + '.lib.jetbrains'
relocate 'org.bstats', mainPackage + '.bstats'
}
processResources {
expand(
version: project.version,
description: project.description,
author: 'Leonardo_DGS',
website: 'https://www.spigotmc.org/resources/45604/'
)
}
tasks.jar.enabled = false
artifacts {
archives shadowJar
}
publishing {
publications {
shadow(MavenPublication) {
publication ->
project.shadow.component(publication)
groupId = project.group
artifactId = project.name
version = project.version
}
}
repositories {
maven {
def snapshotUrl = "https://repo.codemc.io/repository/maven-snapshots/"
def releaseUrl = "https://repo.codemc.io/repository/maven-releases/"
url = project.version.endsWith("SNAPSHOT") ? snapshotUrl : releaseUrl
def mavenUsername = System.getenv("GRADLE_PROJECT_MAVEN_USERNAME") ? System.getenv("GRADLE_PROJECT_MAVEN_USERNAME") : null
def mavenPassword = System.getenv("GRADLE_PROJECT_MAVEN_PASSWORD") ? System.getenv("GRADLE_PROJECT_MAVEN_PASSWORD") : null
if (mavenUsername != null && mavenPassword != null) {
credentials {
username = mavenUsername
password = mavenPassword
}
}
}
}
}