66 lines
1.8 KiB
Plaintext
66 lines
1.8 KiB
Plaintext
import org.gradle.api.credentials.PasswordCredentials
|
|
|
|
plugins {
|
|
id("java-library")
|
|
id("maven-publish")
|
|
id("com.github.johnrengelman.shadow") version("8.1.1")
|
|
}
|
|
|
|
allprojects {
|
|
apply(plugin = "java-library")
|
|
apply(plugin = "maven-publish")
|
|
apply(plugin = "com.github.johnrengelman.shadow")
|
|
|
|
group = "de.weapie"
|
|
version = "2024.07.12-01"
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
}
|
|
|
|
dependencies {
|
|
implementation(rootProject.libs.lombok)
|
|
annotationProcessor(rootProject.libs.lombok)
|
|
|
|
implementation(rootProject.libs.annotations)
|
|
annotationProcessor(rootProject.libs.annotations)
|
|
|
|
testAnnotationProcessor(rootProject.libs.lombok)
|
|
testImplementation(rootProject.libs.lombok)
|
|
}
|
|
|
|
tasks.withType<JavaCompile> {
|
|
sourceCompatibility = JavaVersion.VERSION_17.toString()
|
|
targetCompatibility = JavaVersion.VERSION_17.toString()
|
|
// options
|
|
options.encoding = "UTF-8"
|
|
options.isIncremental = true
|
|
}
|
|
|
|
publishing {
|
|
repositories {
|
|
maven {
|
|
name = "jfHomeRepoPrivate"
|
|
url = uri("https://repo.jf.home/private")
|
|
credentials(PasswordCredentials::class)
|
|
authentication {
|
|
create<BasicAuthentication>("basic")
|
|
}
|
|
}
|
|
}
|
|
publications {
|
|
create<MavenPublication>("maven") {
|
|
groupId = "${project.group}"
|
|
artifactId = "${project.name}"
|
|
version = "${project.version}"
|
|
from(components["java"])
|
|
}
|
|
}
|
|
}
|
|
|
|
tasks.shadowJar {
|
|
archiveBaseName.set("${project.name}")
|
|
archiveVersion.set("${project.version}")
|
|
archiveFileName.set("${archiveBaseName.get()}-${archiveVersion.get()}.jar")
|
|
}
|
|
} |