2018-12-18 20:13:05 +01:00
|
|
|
dependencies {
|
2021-03-09 10:36:07 +01:00
|
|
|
compile "net.playeranalytics:platform-abstraction-layer-api:$palVersion"
|
2019-04-03 21:44:26 +02:00
|
|
|
compile project(":api")
|
2020-05-23 11:13:11 +02:00
|
|
|
compileOnly project(":extensions")
|
2019-03-20 12:37:56 +01:00
|
|
|
compile project(path: ":extensions", configuration: 'shadow')
|
2018-12-18 20:13:05 +01:00
|
|
|
compile "org.apache.commons:commons-text:$commonsTextVersion"
|
2020-01-06 12:18:42 +01:00
|
|
|
compile "org.apache.commons:commons-compress:$commonsCompressVersion"
|
2018-12-18 20:13:05 +01:00
|
|
|
compile "com.github.ben-manes.caffeine:caffeine:$caffeineVersion"
|
2021-03-15 14:28:36 +01:00
|
|
|
implementation "com.h2database:h2:$h2Version"
|
|
|
|
implementation "mysql:mysql-connector-java:$mysqlVersion"
|
|
|
|
implementation "org.xerial:sqlite-jdbc:$sqliteVersion"
|
2018-12-18 20:13:05 +01:00
|
|
|
compile "com.zaxxer:HikariCP:$hikariVersion"
|
2019-01-08 20:36:13 +01:00
|
|
|
compile "org.slf4j:slf4j-nop:$slf4jVersion"
|
2018-12-18 20:13:05 +01:00
|
|
|
compile "org.slf4j:slf4j-api:$slf4jVersion"
|
|
|
|
compile "com.maxmind.geoip2:geoip2:$geoIpVersion"
|
2019-08-06 07:11:05 +02:00
|
|
|
compile "com.google.code.gson:gson:$gsonVersion"
|
2019-03-20 16:17:23 +01:00
|
|
|
|
2019-04-03 21:44:26 +02:00
|
|
|
testCompile project(":api")
|
2019-08-06 07:11:05 +02:00
|
|
|
testCompile "com.google.code.gson:gson:$gsonVersion"
|
2018-12-18 20:13:05 +01:00
|
|
|
}
|
|
|
|
|
2019-12-07 19:12:45 +01:00
|
|
|
import org.apache.tools.ant.filters.ReplaceTokens
|
|
|
|
task updateVersion(type: Copy) {
|
|
|
|
from('src/main/resources') {
|
|
|
|
include 'plugin.yml'
|
|
|
|
include 'bungee.yml'
|
2019-12-08 09:26:24 +01:00
|
|
|
include 'nukkit.yml'
|
2019-12-07 19:12:45 +01:00
|
|
|
}
|
|
|
|
into 'build/sources/resources/'
|
|
|
|
filter(ReplaceTokens, tokens: [version: '' + project.ext.fullVersion])
|
|
|
|
}
|
|
|
|
processResources {
|
|
|
|
dependsOn updateVersion
|
|
|
|
from 'build/sources/resources'
|
|
|
|
}
|
|
|
|
|
2018-12-18 20:13:05 +01:00
|
|
|
shadowJar {
|
2019-12-07 19:12:45 +01:00
|
|
|
dependsOn processResources
|
2018-12-19 18:08:07 +01:00
|
|
|
configurations = [project.configurations.compile]
|
|
|
|
|
|
|
|
// Exclude these files
|
|
|
|
exclude "**/*.svg"
|
|
|
|
exclude "**/*.psd"
|
|
|
|
|
2019-08-01 19:35:33 +02:00
|
|
|
exclude "**/module-info.class"
|
2021-03-15 14:28:36 +01:00
|
|
|
exclude 'META-INF/versions/' // Causes Sponge to crash
|
2021-03-15 12:56:36 +01:00
|
|
|
exclude 'org/apache/http/**/*' // Unnecessary http client depended on by geolite2 implementation
|
|
|
|
exclude 'mozilla/**/*'
|
2020-10-12 09:36:02 +02:00
|
|
|
|
2018-12-18 20:13:05 +01:00
|
|
|
relocate 'com.maxmind', 'plan.com.maxmind'
|
|
|
|
relocate 'com.fasterxml', 'plan.com.fasterxml'
|
|
|
|
relocate 'com.zaxxer', 'plan.com.zaxxer'
|
2019-10-25 13:39:55 +02:00
|
|
|
relocate 'com.google.protobuf', 'plan.com.google.protobuf'
|
|
|
|
relocate 'com.google.gson', 'plan.com.google.gson'
|
|
|
|
relocate 'com.google.errorprone', 'plan.com.google.errorprone'
|
2018-12-18 20:13:05 +01:00
|
|
|
relocate 'org.h2', 'plan.org.h2'
|
|
|
|
relocate 'org.bstats', 'plan.org.bstats'
|
|
|
|
relocate 'org.slf4j', 'plan.org.slf4j'
|
2019-04-03 22:14:55 +02:00
|
|
|
|
|
|
|
// Exclude test dependencies
|
|
|
|
exclude "org/junit/**/*"
|
|
|
|
exclude "org/opentest4j/**/*"
|
|
|
|
exclude "org/checkerframework/**/*"
|
|
|
|
exclude "org/apiguardian/**/*"
|
|
|
|
exclude "org/mockito/**/*"
|
|
|
|
exclude "org/selenium/**/*"
|
|
|
|
exclude "org/jayway/**/*"
|
2019-10-25 13:39:55 +02:00
|
|
|
exclude "google/protobuf/**/*"
|
|
|
|
exclude "jargs/gnu/**/*"
|
2018-12-18 20:13:05 +01:00
|
|
|
}
|