summaryrefslogtreecommitdiffstats
path: root/build.gradle
diff options
context:
space:
mode:
Diffstat (limited to 'build.gradle')
-rw-r--r--build.gradle138
1 files changed, 14 insertions, 124 deletions
diff --git a/build.gradle b/build.gradle
index 7bb52b03..c6183574 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,139 +1,29 @@
plugins {
id 'java'
- id 'com.github.johnrengelman.shadow' version '6.1.0'
- id 'maven-publish'
+ id 'com.github.johnrengelman.shadow' version '7.0.0'
}
-group = 'com.leonardobishop'
-version = '2.18'
+defaultTasks 'allJar'
-processResources {
- duplicatesStrategy = 'include'
- from(sourceSets.main.resources.srcDirs) {
- include 'plugin.yml'
- expand('version': project.version)
- }
-}
+subprojects {
+ apply plugin: 'java'
-repositories {
- // Spigot
- maven { url = 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/' }
- // ASkyBlock, BentoBox
- maven { url = 'https://repo.codemc.org/repository/maven-public/' }
- // uSkyBlock
- maven { url = 'https://raw.github.com/rlf/uSkyBlock/mvn-repo/' }
- // Citizens
- maven { url = 'https://repo.citizensnpcs.co/' }
- // MythicMobs
- maven { url = 'https://mvn.lumine.io/repository/maven-public/' }
- // PlaceholderAPI
- maven { url = 'https://repo.extendedclip.com/content/repositories/placeholderapi/' }
- // EssentialsX
- maven { url = 'https://repo.essentialsx.net/releases/' }
- // JitPack (IridiumSkyblock, ShopGUI+)
- maven { url = 'https://jitpack.io' }
- // CoreProtect
- maven { url = 'https://maven.playpro.com/' }
- // bStats
- maven { url = uri('https://repo.codemc.org/repository/maven-public') }
- mavenCentral()
-}
+ group = 'com.leonardobishop'
+ version = '3.0'
-dependencies {
- // Spigot
- compileOnly ('org.spigotmc:spigot-api:1.16.4-R0.1-SNAPSHOT') {
- exclude group: 'net.md-5', module: 'bungeecord-chat'
- exclude group: 'com.google.guava', module: 'guava'
- exclude group: 'org.yaml', module: 'snakeyaml'
- }
- // ASkyBlock
- compileOnly ('com.wasteofplastic:askyblock:3.0.9.4') {
- exclude group: 'net.milkbowl.vault', module: 'VaultAPI'
- }
- // BentoBox (bSkyBlock)
- compileOnly ('world.bentobox:bentobox:1.15.5-SNAPSHOT') {
- exclude group: 'org.eclipse.jdt', module: 'org.eclipse.jdt.annotation'
- exclude group: 'org.mongodb', module: 'mongodb-driver'
- }
- // IridiumSkyblock
- // TODO fix whenever repo is up
- // compileOnly 'com.github.Iridium-Development:IridiumSkyblock:master-SNAPSHOT'
- // download from spigot and add to /libs/ yourself
- // uSkyBlock
- compileOnly 'com.github.rlf:uSkyBlock-API:2.6.4'
- // MythicMobs
- compileOnly 'io.lumine.xikage:MythicMobs:4.11.0-BETA'
- // Citizens
- compileOnly ('net.citizensnpcs:citizens:2.0.27-SNAPSHOT') {
- exclude group: 'net.citizensnpcs', module: 'citizens-main'
- exclude group: 'net.citizensnpcs', module: 'citizens-v1_8_R3'
- exclude group: 'net.citizensnpcs', module: 'citizens-v1_12_R1'
- exclude group: 'net.citizensnpcs', module: 'citizens-v1_13_R2'
- exclude group: 'net.citizensnpcs', module: 'citizens-v1_14_R1'
- exclude group: 'net.citizensnpcs', module: 'citizens-v1_15_R1'
- exclude group: 'net.citizensnpcs', module: 'citizens-v1_16_R3'
- }
- // PlaceholderAPI
- compileOnly 'me.clip:placeholderapi:2.10.9'
- // EssentialsX
- compileOnly "net.ess3:EssentialsX:2.18.2"
- // ShopGUI+
- compileOnly 'com.github.brcdev-minecraft:shopgui-api:master-SNAPSHOT'
- // CoreProtect
- compileOnly ('net.coreprotect:coreprotect:2.18.2') {
- exclude group: 'com.sk89q.worldedit', module: 'worldedit-bukkit'
- }
- // bStats
- implementation 'org.bstats:bstats-bukkit-lite:1.8'
- // HikariCP
- implementation 'com.zaxxer:HikariCP:4.0.3'
- // slf4j
- implementation 'org.slf4j:slf4j-simple:1.7.30'
+ sourceCompatibility = 1.8
+ targetCompatibility = 1.8
- compileOnly fileTree(dir: 'libs', includes: ['*.jar'])
}
-shadowJar {
- relocate 'org.bstats', 'com.leonardobishop.quests.libs.bstats'
- relocate 'com.zaxxer.hikari', 'com.leonardobishop.quests.libs.hikaricp'
- relocate 'org.slf4j', 'com.leonardobishop.quests.libs.slf4j'
- archiveClassifier.set('')
-}
-
-publishing {
- publications {
- maven(MavenPublication) {
- groupId = 'com.leonardobishop'
- artifactId = 'quests'
- version = project.version
-
- from components.java
- pom.withXml {
- asNode().dependencies.dependency.each { dep ->
- dep.parent().remove(dep)
- }
- }
- }
- }
-
- repositories {
- maven {
- credentials {
- username = project.findProperty('mavenUser') ?: System.getenv('MAVEN_USER')
- password = project.findProperty('mavenPassword') ?: System.getenv('MAVEN_PASSWORD')
- }
- url = "https://repo.leonardobishop.com/releases/"
+task allJar( type: Jar, dependsOn: subprojects.tasks['build'] ) {
+ subprojects.each { subproject ->
+ from subproject.configurations.archives.allArtifacts.files.collect {
+ zipTree(it)
}
}
}
-jar.enabled = true
-
-tasks.build {
- dependsOn(tasks.shadowJar)
-}
-
-compileJava {
- sourceCompatibility = '1.8'
- targetCompatibility = '1.8'
+artifacts {
+ archives allJar
}