-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathbuild.gradle.kts
70 lines (59 loc) · 1.85 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
plugins {
kotlin("jvm") version "1.9.22"
application
`maven-publish`
}
group = "io.heartpattern"
version = "2.0.7-SNAPSHOT"
repositories {
maven("https://repo.heartpattern.io/repository/maven-public/")
}
dependencies {
implementation(kotlin("stdlib"))
implementation("com.github.ajalt.clikt", "clikt", "3.0.1")
implementation("org.ow2.asm", "asm", "9.6")
implementation("org.ow2.asm", "asm-commons", "9.6")
implementation("org.ow2.asm", "asm-tree", "9.6")
implementation("me.tongfei", "progressbar", "0.9.3")
implementation("io.heartpattern","mcversions","1.0.3-SNAPSHOT")
testImplementation(kotlin("test"))
testImplementation(kotlin("test-junit"))
}
application {
mainClass.set( "io.heartpattern.mcremapper.commandline.MCRemapperAppKt" )
}
tasks {
compileKotlin {
kotlinOptions {
freeCompilerArgs = listOf("-progressive")
}
}
create<Jar>("sourcesJar") {
archiveClassifier.set("sources")
from(sourceSets["main"].allSource)
}
}
if("maven.username" in properties && "maven.password" in properties){
publishing{
repositories{
maven(
if(version.toString().endsWith("SNAPSHOT"))
"https://repo.heartpattern.io/repository/maven-public-snapshots/"
else
"https://repo.heartpattern.io/repository/maven-public-releases/"
){
credentials{
username = properties["maven.username"].toString()
password = properties["maven.password"].toString()
}
}
}
publications{
create<MavenPublication>("maven"){
artifactId = "mcremapper"
from(components["java"])
artifact(tasks["sourcesJar"])
}
}
}
}