Skip to content
This repository has been archived by the owner on Jun 9, 2022. It is now read-only.

Commit

Permalink
Improve Shadow plugin configuration
Browse files Browse the repository at this point in the history
Previously it was applied to all projects, which is unnecessary and
slows the build down.

BiomeMapping is now shaded to avoid conflicts with other plugins.
  • Loading branch information
0dinD committed Mar 9, 2022
1 parent ecb104a commit 2f54917
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 20 deletions.
6 changes: 3 additions & 3 deletions Support-WorldEdit-6/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
dependencies {
shadow 'org.spigotmc:spigot-api:1.8.8-R0.1-SNAPSHOT'
shadow 'com.sk89q.worldedit:worldedit-bukkit:6.1.5'
shadow 'com.sk89q.worldedit:worldedit-core:6.1.4-SNAPSHOT'
compileOnly 'org.spigotmc:spigot-api:1.8.8-R0.1-SNAPSHOT'
compileOnly 'com.sk89q.worldedit:worldedit-bukkit:6.1.5'
compileOnly 'com.sk89q.worldedit:worldedit-core:6.1.4-SNAPSHOT'
}
4 changes: 2 additions & 2 deletions Support-WorldEdit-7/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
dependencies {
shadow 'org.spigotmc:spigot-api:1.13.2-R0.1-SNAPSHOT'
shadow 'com.sk89q.worldedit:worldedit-bukkit:7.1.0-SNAPSHOT'
compileOnly 'org.spigotmc:spigot-api:1.13.2-R0.1-SNAPSHOT'
compileOnly 'com.sk89q.worldedit:worldedit-bukkit:7.1.0-SNAPSHOT'
}
21 changes: 6 additions & 15 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,22 +1,12 @@
import org.apache.tools.ant.filters.ReplaceTokens

buildscript {
repositories {
gradlePluginPortal()
}

dependencies {
classpath 'gradle.plugin.com.github.johnrengelman:shadow:7.1.2'
}
}

plugins {
id "com.github.johnrengelman.shadow" version "7.1.2"
id "xyz.jpenilla.run-paper" version "1.0.6"
}

allprojects {
apply plugin: 'java-library'
apply plugin: 'com.github.johnrengelman.shadow'

group = pluginGroup
version = pluginVersion
Expand Down Expand Up @@ -63,19 +53,19 @@ allprojects {
}

dependencies {
shadow 'com.google.code.findbugs:jsr305:3.0.2'
compileOnly 'com.google.code.findbugs:jsr305:3.0.2'
//shadow 'org.spigotmc:spigot-api:1.8.8-R0.1-SNAPSHOT'
//shadow 'org.spigotmc:spigot-api:1.12.2-R0.1-SNAPSHOT'
//shadow 'org.spigotmc:spigot-api:1.13.2-R0.1-SNAPSHOT'
//shadow 'org.spigotmc:spigot-api:1.14.2-R0.1-SNAPSHOT'
//shadow 'org.spigotmc:spigot-api:1.15.2-R0.1-SNAPSHOT'
//shadow 'org.spigotmc:spigot-api:1.16.5-R0.1-SNAPSHOT'
//shadow 'org.spigotmc:spigot-api:1.17-R0.1-SNAPSHOT'
shadow 'org.spigotmc:spigot-api:1.18-R0.1-SNAPSHOT'
shadow 'com.github.MilkBowl:VaultAPI:1.7'
compileOnly 'org.spigotmc:spigot-api:1.18-R0.1-SNAPSHOT'
compileOnly 'com.github.MilkBowl:VaultAPI:1.7'
implementation 'net.wesjd:anvilgui:1.5.3-SNAPSHOT'
implementation "io.papermc:paperlib:1.0.5"
shadow 'com.comphenix.protocol:ProtocolLib:4.7.0'
compileOnly 'com.comphenix.protocol:ProtocolLib:4.7.0'
implementation project('Support-WorldEdit-6')
implementation project('Support-WorldEdit-7')
implementation project(":adapters")
Expand All @@ -87,6 +77,7 @@ shadowJar {
classifier = ''
relocate 'io.papermc.lib', 'com.gmail.val59000mc.paperlib'
relocate 'net.wesjd.anvilgui', 'com.gmail.val59000mc.anvilgui'
relocate 'com.pieterdebot.biomemapping', 'com.gmail.val59000mc.biomemapping'
}

build.dependsOn(shadowJar)
Expand Down

0 comments on commit 2f54917

Please sign in to comment.