-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
89 lines (80 loc) · 2.63 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
plugins {
id 'org.jetbrains.kotlin.jvm' version '1.9.21'
id 'org.jetbrains.kotlin.plugin.serialization' version '1.9.21'
id 'maven-publish'
id 'signing'
}
group = 'com.hiczp'
version = '2.1.0-SNAPSHOT'
description = 'Retrofit inspired Http client base on ktor-client'
repositories {
mavenCentral()
}
// https://mvnrepository.com/artifact/io.ktor/ktor-client-core
def ktor_version = '2.3.7'
dependencies {
api "io.ktor:ktor-client-core:$ktor_version"
implementation 'org.jetbrains.kotlin:kotlin-reflect'
testImplementation 'org.jetbrains.kotlin:kotlin-test'
testImplementation "io.ktor:ktor-client-cio:$ktor_version"
testImplementation "io.ktor:ktor-client-content-negotiation:$ktor_version"
testImplementation "io.ktor:ktor-serialization-kotlinx-json:$ktor_version"
testImplementation "io.ktor:ktor-client-logging:$ktor_version"
testImplementation 'ch.qos.logback:logback-classic:1.4.14'
testImplementation "io.ktor:ktor-client-mock:$ktor_version"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.1'
}
test {
useJUnitPlatform()
}
kotlin {
jvmToolchain(17)
}
java {
withJavadocJar()
withSourcesJar()
}
publishing {
repositories {
maven {
url = 'https://oss.sonatype.org/service/local/staging/deploy/maven2/'
credentials {
username = project.properties.ossUsername
password = project.properties.ossPassword
}
}
}
publications {
mavenJava(MavenPublication) {
from components.java
pom {
name = project.name
description = project.description
url = 'https://github.com/czp3009/caeruleum'
licenses {
license {
name = 'Apache License Version 2.0'
url = 'https://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
developers {
developer {
id = 'czp3009'
name = 'czp3009'
email = '[email protected]'
url = 'https://www.hiczp.com'
}
}
scm {
connection = 'scm:git:git://github.com/czp3009/caeruleum.git'
developerConnection = 'scm:git:ssh://github.com/czp3009/caeruleum.git'
url = 'https://github.com/czp3009/caeruleum'
}
}
}
}
}
signing {
required { gradle.taskGraph.hasTask(publish) }
sign publishing.publications.mavenJava
}