-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
96 lines (76 loc) · 2.25 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
allprojects {
if(project.name.contains('Example'))
return
group 'br.com.gamemods.kotlinfun'
version '0.3-SNAPSHOT'
apply plugin: 'kotlin'
repositories {
mavenCentral()
maven { url = 'https://oss.sonatype.org/content/repositories/snapshots' }
maven { url = 'https://hub.spigotmc.org/nexus/content/groups/public/' }
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version"
testCompile group: 'junit', name: 'junit', version: '4.11'
}
}
buildscript {
ext.kotlin_version = '1.0.4'
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath 'com.github.jengelman.gradle.plugins:shadow:1.2.3'
}
}
subprojects {
if(project.name.contains('Example'))
return
apply plugin: 'kotlin'
apply plugin: 'com.github.johnrengelman.shadow'
sourceCompatibility = 1.6
targetCompatibility = 1.6
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
dependencies {
compile rootProject
}
shadowJar {
dependencies {
include dependency("org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version")
include dependency("org.jetbrains.kotlin:kotlin-reflect:$kotlin_version")
include dependency("org.jetbrains.kotlin:kotlin-runtime:$kotlin_version")
include dependency(rootProject)
}
classifier = null
baseName = rootProject.name+'-'+project.name
}
build.finalizedBy shadowJar
task copyFinalJar(type: Copy) {
from "${project.buildDir}/libs/${shadowJar.archiveName}"
into "${rootProject.buildDir}"
}
shadowJar.finalizedBy(copyFinalJar)
}
project(':BungeeChat') {
dependencies {
compile 'net.md-5:bungeecord-chat:1.10-SNAPSHOT'
}
shadowJar.enabled = false
}
project(':UniversalPlugin') {
dependencies {
compile project(':BungeePlugin')
compile project(':SpigotPlugin')
}
shadowJar {
dependencies {
include project(':BungeePlugin')
include project(':BukkitPlugin')
include project(':SpigotPlugin')
}
}
}