/
build.gradle
126 lines (105 loc) · 3.36 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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
buildscript {
repositories {
jcenter()
}
dependencies {
classpath "org.jetbrains.dokka:dokka-gradle-plugin:0.9.17"
}
}
plugins {
id 'org.jetbrains.kotlin.jvm' version '1.3.20'
id 'io.codearte.nexus-staging' version '0.20.0'
}
sourceCompatibility = 1.8
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
apply plugin: 'jacoco'
apply plugin: 'org.jetbrains.dokka'
apply plugin: 'maven'
apply plugin: 'signing'
group 'com.github.shynixn'
version '1.2'
test {
useJUnitPlatform()
testLogging.showStandardStreams = true
failFast = true
}
jacocoTestReport {
reports {
xml.enabled true
html.enabled false
}
}
task sourceJar(type: Jar) {
classifier "sources"
from sourceSets.main.allJava
}
task dokkaJavadoc(type: org.jetbrains.dokka.gradle.DokkaTask) {
outputFormat = 'javadoc'
outputDirectory = "$buildDir/javadoc"
}
task javadocJar(type: Jar, dependsOn: dokkaJavadoc) {
classifier = 'javadoc'
from "$buildDir/javadoc"
}
artifacts {
archives jar
archives sourceJar
archives javadocJar
}
signing {
required { gradle.taskGraph.hasTask("uploadArchives") }
sign configurations.archives
}
uploadArchives {
repositories {
mavenDeployer {
beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) }
repository(url: "https://oss.sonatype.org/service/local/staging/deploy/maven2/") {
authentication(userName: findProperty('ossrhUsername'), password: findProperty('ossrhPassword'))
}
snapshotRepository(url: "https://oss.sonatype.org/content/repositories/snapshots/") {
authentication(userName: findProperty('ossrhUsername'), password: findProperty('ossrhPassword'))
}
pom.project {
name 'DiscordWebhook-Ktl'
packaging 'jar'
description 'DiscordWebhook-Ktl is a wrapper around the discord webhook bot REST api.'
url 'https://github.com/Shynixn/DiscordWebhook-Ktl'
scm {
connection 'scm:git:git://github.com/Shynixn/DiscordWebhook-Ktl.git'
developerConnection 'scm:git:ssh://github.com:Shynixn/DiscordWebhook-Ktl.git'
url 'http://github.com/Shynixn/DiscordWebhook-Ktl.git/tree/master'
}
licenses {
license {
name 'MIT License'
url 'http://www.opensource.org/licenses/mit-license.php'
}
}
developers {
developer {
name 'Shynixn'
url 'https://github.com/Shynixn'
}
}
}
}
}
}
repositories {
mavenCentral()
mavenLocal()
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
compile group: 'org.apache.cxf', name: 'cxf-rt-rs-client', version: '3.3.0'
compile group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.9.8'
testCompile 'org.mockito:mockito-core:2.23.0'
testCompile group: 'org.junit.jupiter', name: 'junit-jupiter-api', version: '5.3.1'
testRuntime group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: '5.3.1'
}