2015-04-13 07:25:48 +02:00
|
|
|
plugins {
|
2015-08-13 02:20:41 +02:00
|
|
|
id 'java'
|
|
|
|
id 'maven-publish'
|
|
|
|
id "com.jfrog.artifactory" version "3.1.1"
|
2015-04-13 07:25:48 +02:00
|
|
|
}
|
2015-03-10 01:28:41 +01:00
|
|
|
|
2015-03-31 11:39:34 +02:00
|
|
|
println 'Compiling LibsDisguises via Gradle ver. ' + gradle.gradleVersion
|
|
|
|
|
2015-03-10 19:58:05 +01:00
|
|
|
sourceCompatibility = '1.7'
|
2015-08-02 01:24:18 +02:00
|
|
|
ext.spigotVersion = '1.8.8-R0.1-SNAPSHOT'
|
2015-03-10 01:28:41 +01:00
|
|
|
|
2016-01-22 06:41:45 +01:00
|
|
|
ext.disguisesVersion = '8.6.8'
|
2015-07-01 22:02:57 +02:00
|
|
|
|
2015-03-10 01:28:41 +01:00
|
|
|
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
2015-08-13 02:20:41 +02:00
|
|
|
|
2015-03-10 01:28:41 +01:00
|
|
|
maven {
|
|
|
|
name 'Spigot'
|
|
|
|
url 'https://hub.spigotmc.org/nexus/content/groups/public/'
|
|
|
|
}
|
2015-08-13 02:20:41 +02:00
|
|
|
|
2015-03-10 01:28:41 +01:00
|
|
|
maven {
|
2016-01-27 04:55:16 +01:00
|
|
|
url 'https://oss.sonatype.org/content/groups/public/'
|
2015-03-10 01:28:41 +01:00
|
|
|
}
|
2015-08-13 02:20:41 +02:00
|
|
|
|
2015-03-10 01:28:41 +01:00
|
|
|
maven {
|
2015-07-06 14:23:32 +02:00
|
|
|
name 'dmulloy2-repo'
|
|
|
|
url 'http://repo.dmulloy2.net/content/groups/public/'
|
2015-03-10 01:28:41 +01:00
|
|
|
}
|
2016-01-27 04:55:16 +01:00
|
|
|
|
|
|
|
flatDir {
|
|
|
|
dir 'libs'
|
|
|
|
}
|
2015-03-10 01:28:41 +01:00
|
|
|
}
|
|
|
|
|
2015-08-13 02:20:41 +02:00
|
|
|
task sourceJar(type: Jar, dependsOn: classes) {
|
2015-07-01 20:44:32 +02:00
|
|
|
classifier = 'sources'
|
|
|
|
from sourceSets.main.allSource
|
|
|
|
}
|
|
|
|
|
2015-08-13 02:20:41 +02:00
|
|
|
task javadocJar(type: Jar, dependsOn: javadoc) {
|
2015-07-01 20:44:32 +02:00
|
|
|
classifier = 'javadoc'
|
|
|
|
from javadoc.destinationDir
|
|
|
|
}
|
|
|
|
|
|
|
|
jar {
|
|
|
|
baseName "LibsDisguises"
|
|
|
|
}
|
|
|
|
|
|
|
|
artifacts {
|
|
|
|
archives sourceJar
|
|
|
|
archives javadocJar
|
|
|
|
archives jar
|
|
|
|
}
|
|
|
|
|
2015-07-01 20:29:40 +02:00
|
|
|
publishing {
|
|
|
|
publications {
|
|
|
|
mavenJava(MavenPublication) {
|
|
|
|
groupId 'LibsDisguises'
|
|
|
|
artifactId 'LibsDisguises'
|
2015-07-01 22:02:57 +02:00
|
|
|
version disguisesVersion + '-SNAPSHOT'
|
2015-07-01 20:29:40 +02:00
|
|
|
from components.java
|
2015-07-01 22:02:57 +02:00
|
|
|
artifact sourceJar {
|
2015-07-01 20:44:32 +02:00
|
|
|
classifier = 'sources'
|
|
|
|
}
|
2015-07-01 22:02:57 +02:00
|
|
|
artifact javadocJar {
|
2015-07-01 20:44:32 +02:00
|
|
|
classifier = 'javadoc'
|
|
|
|
}
|
2015-07-01 20:29:40 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-07-01 19:47:20 +02:00
|
|
|
artifactoryPublish.skip = false
|
|
|
|
|
2015-07-01 15:33:25 +02:00
|
|
|
artifactory {
|
|
|
|
contextUrl = 'http://localhost:8081/artifactory'
|
|
|
|
publish {
|
2015-08-13 02:20:41 +02:00
|
|
|
repository {
|
|
|
|
repoKey = 'libs-snapshot-local'
|
|
|
|
username = '${artifactory_user}'
|
|
|
|
password = '${artifactory_password}'
|
|
|
|
}
|
|
|
|
defaults {
|
|
|
|
publications('mavenJava')
|
|
|
|
}
|
2015-07-01 15:33:25 +02:00
|
|
|
}
|
2015-08-13 02:20:41 +02:00
|
|
|
resolve {
|
|
|
|
repoKey = 'repo'
|
2015-07-01 15:33:25 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-03-10 01:28:41 +01:00
|
|
|
file('libs').mkdirs()
|
|
|
|
|
2015-03-26 00:23:16 +01:00
|
|
|
ant.get src: 'https://www.dropbox.com/s/1ofgubrldjwamnk/spigot.jar?dl=1', dest: file('libs'), verbose: false, skipexisting: true
|
2015-03-10 01:28:41 +01:00
|
|
|
|
|
|
|
dependencies {
|
2016-01-27 04:55:16 +01:00
|
|
|
compile "org.spigotmc:spigot-api:$project.ext.spigotVersion"
|
2016-01-31 15:29:41 +01:00
|
|
|
compile 'com.comphenix.protocol:ProtocolLib:3.6.5'
|
2016-01-27 04:55:16 +01:00
|
|
|
compile name: 'spigot'
|
2015-03-10 01:28:41 +01:00
|
|
|
testCompile group: 'junit', name: 'junit', version: '4.10'
|
|
|
|
}
|