Refactor build scripts and Jenkinsfile
This commit is contained in:
1 parent
0d31d85fd4
commit
de03444bc6
5 files changed
+61
-116
No files matched your search
+7
-27
@@ -1,6 +1,6 @@
|
||||
|
||||
plugins {
|
||||
id("java")
|
||||
id("maven-publish")
|
||||
}
|
||||
|
||||
allprojects {
|
||||
@@ -10,41 +10,21 @@ allprojects {
|
||||
}
|
||||
|
||||
subprojects {
|
||||
apply<JavaLibraryPlugin>()
|
||||
apply(plugin = "maven-publish")
|
||||
apply(plugin = "java-library")
|
||||
|
||||
java {
|
||||
toolchain {
|
||||
languageVersion.set(JavaLanguageVersion.of(21))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
tasks {
|
||||
jar {
|
||||
enabled = true
|
||||
}
|
||||
}
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("mavenJava") {
|
||||
from(components["java"])
|
||||
}
|
||||
dependencies {
|
||||
compileOnly("io.papermc.paper:paper-api:1.21.6-R0.1-SNAPSHOT")
|
||||
}
|
||||
|
||||
repositories{
|
||||
maven {
|
||||
name = "nexus"
|
||||
url = uri("https://repo.alttd.com/repository/alttd-snapshot/")
|
||||
credentials {
|
||||
username = project.property("alttdDevPublishUser") as String
|
||||
password = project.property("alttdDevPublishPass") as String
|
||||
}
|
||||
tasks {
|
||||
jar {
|
||||
from(sourceSets.main.get().output)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly("io.papermc.paper:paper-api:1.21.6-R0.1-SNAPSHOT")
|
||||
}
|
||||
Reference in new issue
Block a user