-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle.kts
95 lines (75 loc) · 2.09 KB
/
build.gradle.kts
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
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
val ktorVersion = "1.5.4"
val githubProject = "bluefireoly/kotlin-smtp"
plugins {
kotlin("jvm") version "1.5.0"
`java-library`
`maven-publish`
signing
}
group = "net.axay"
version = "0.0.1"
description = "An implementation of the SMTP server protocol written in Kotlin"
repositories {
mavenCentral()
}
dependencies {
implementation(kotlin("stdlib"))
api("io.ktor:ktor-network:$ktorVersion")
testImplementation("org.junit.jupiter:junit-jupiter:5.7.1")
}
tasks {
withType<JavaCompile> {
options.encoding = "UTF-8"
options.release.set(11)
}
withType<KotlinCompile> {
kotlinOptions.jvmTarget = "11"
}
test {
useJUnitPlatform()
}
}
java {
withSourcesJar()
withJavadocJar()
}
signing {
sign(publishing.publications)
}
publishing {
repositories {
maven("https://oss.sonatype.org/service/local/staging/deploy/maven2") {
name = "ossrh"
credentials(PasswordCredentials::class)
}
}
publications {
create<MavenPublication>(project.name) {
from(components["java"])
this.groupId = project.group.toString()
this.artifactId = project.name
this.version = project.version.toString()
pom {
name.set(project.name)
description.set(project.description)
developers {
developer {
name.set("bluefireoly")
}
}
licenses {
license {
name.set("The Apache License, Version 2.0")
url.set("https://www.apache.org/licenses/LICENSE-2.0.txt")
}
}
url.set("https://github.com/$githubProject")
scm {
connection.set("scm:git:git://github.com/$githubProject.git")
url.set("https://github.com/$githubProject/tree/main")
}
}
}
}
}