mirror of
https://github.com/FancyInnovations/FancyPlugins.git
synced 2025-12-06 07:43:36 +00:00
config: Add VERSION file and configure publishing to maven repo
This commit is contained in:
@@ -24,6 +24,38 @@ dependencies {
|
||||
}
|
||||
|
||||
tasks {
|
||||
publishing {
|
||||
repositories {
|
||||
maven {
|
||||
name = "fancyinnovationsReleases"
|
||||
url = uri("https://repo.fancyinnovations.com/releases")
|
||||
credentials(PasswordCredentials::class)
|
||||
authentication {
|
||||
isAllowInsecureProtocol = true
|
||||
create<BasicAuthentication>("basic")
|
||||
}
|
||||
}
|
||||
|
||||
maven {
|
||||
name = "fancyinnovationsSnapshots"
|
||||
url = uri("https://repo.fancyinnovations.com/snapshots")
|
||||
credentials(PasswordCredentials::class)
|
||||
authentication {
|
||||
isAllowInsecureProtocol = true
|
||||
create<BasicAuthentication>("basic")
|
||||
}
|
||||
}
|
||||
}
|
||||
publications {
|
||||
create<MavenPublication>("maven") {
|
||||
groupId = "de.oliver"
|
||||
artifactId = "config"
|
||||
version = getCFGVersion()
|
||||
from(project.components["java"])
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
compileJava {
|
||||
options.encoding = Charsets.UTF_8.name()
|
||||
options.release.set(17) //TODO change to 21, once 1.19.4 support is dropped
|
||||
@@ -49,3 +81,7 @@ tasks {
|
||||
java {
|
||||
toolchain.languageVersion.set(JavaLanguageVersion.of(17)) //TODO change to 21, once 1.19.4 support is dropped
|
||||
}
|
||||
|
||||
fun getCFGVersion(): String {
|
||||
return file("VERSION").readText()
|
||||
}
|
||||
Reference in New Issue
Block a user