Fix wrong version in nuvotifier-bungee, added universal back
This commit is contained in:
1 parent
2d5c2c78d2
commit
7812823367
11 files changed
+86
-27
No files matched your search
@@ -3,6 +3,7 @@ plugins {
|
||||
}
|
||||
|
||||
applyPlatformAndCoreConfiguration()
|
||||
applyCommonArtifactoryConfig()
|
||||
|
||||
dependencies {
|
||||
"implementation"("com.google.code.gson:gson:${Versions.GSON}")
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import org.gradle.api.Project
|
||||
import org.gradle.kotlin.dsl.apply
|
||||
import org.gradle.kotlin.dsl.configure
|
||||
import org.gradle.kotlin.dsl.named
|
||||
import org.gradle.api.publish.PublishingExtension
|
||||
import org.gradle.api.publish.maven.MavenPublication
|
||||
import org.gradle.kotlin.dsl.*
|
||||
import org.jfrog.gradle.plugin.artifactory.dsl.ArtifactoryPluginConvention
|
||||
import org.jfrog.gradle.plugin.artifactory.task.ArtifactoryTask
|
||||
|
||||
@@ -34,6 +34,22 @@ fun Project.applyRootArtifactoryConfig() {
|
||||
}
|
||||
|
||||
fun Project.applyCommonArtifactoryConfig() {
|
||||
configure<PublishingExtension> {
|
||||
publications {
|
||||
register<MavenPublication>("maven") {
|
||||
from(components["java"])
|
||||
versionMapping {
|
||||
usage("java-api") {
|
||||
fromResolutionOf("runtimeClasspath")
|
||||
}
|
||||
usage("java-runtime") {
|
||||
fromResolutionResult()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
tasks.named<ArtifactoryTask>("artifactoryPublish") {
|
||||
publications("maven")
|
||||
}
|
||||
|
||||
@@ -1,13 +1,9 @@
|
||||
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
|
||||
import org.gradle.api.Project
|
||||
import org.gradle.api.component.AdhocComponentWithVariants
|
||||
import org.gradle.api.publish.PublishingExtension
|
||||
import org.gradle.api.publish.maven.MavenPublication
|
||||
import org.gradle.kotlin.dsl.apply
|
||||
import org.gradle.kotlin.dsl.configure
|
||||
import org.gradle.kotlin.dsl.get
|
||||
import org.gradle.kotlin.dsl.named
|
||||
import org.gradle.kotlin.dsl.register
|
||||
|
||||
fun Project.applyPlatformAndCoreConfiguration(javaRelease: Int = 17) {
|
||||
applyCommonConfiguration()
|
||||
@@ -21,24 +17,6 @@ fun Project.applyPlatformAndCoreConfiguration(javaRelease: Int = 17) {
|
||||
)
|
||||
|
||||
ext["internalVersion"] = "$version+${rootProject.ext["gitCommitHash"]}"
|
||||
|
||||
configure<PublishingExtension> {
|
||||
publications {
|
||||
register<MavenPublication>("maven") {
|
||||
from(components["java"])
|
||||
versionMapping {
|
||||
usage("java-api") {
|
||||
fromResolutionOf("runtimeClasspath")
|
||||
}
|
||||
usage("java-runtime") {
|
||||
fromResolutionResult()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
applyCommonArtifactoryConfig()
|
||||
}
|
||||
|
||||
fun Project.applyShadowConfiguration() {
|
||||
|
||||
@@ -5,6 +5,7 @@ plugins {
|
||||
}
|
||||
|
||||
applyPlatformAndCoreConfiguration()
|
||||
applyCommonArtifactoryConfig()
|
||||
applyShadowConfiguration()
|
||||
|
||||
repositories {
|
||||
|
||||
@@ -5,6 +5,7 @@ plugins {
|
||||
}
|
||||
|
||||
applyPlatformAndCoreConfiguration()
|
||||
applyCommonArtifactoryConfig()
|
||||
applyShadowConfiguration()
|
||||
|
||||
repositories {
|
||||
@@ -28,7 +29,7 @@ dependencies {
|
||||
tasks.named<Copy>("processResources") {
|
||||
val internalVersion = project.ext["internalVersion"]
|
||||
inputs.property("internalVersion", internalVersion)
|
||||
filesMatching("plugin.yml") {
|
||||
filesMatching("bungee.yml") {
|
||||
expand("internalVersion" to internalVersion)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
name: NuVotifier
|
||||
main: com.vexsoftware.votifier.bungee.NuVotifier
|
||||
version: @app.version@
|
||||
version: "${internalVersion}"
|
||||
author: Ichbinjoe, blakeman8192, Kramer, tuxed
|
||||
@@ -3,6 +3,7 @@ plugins {
|
||||
}
|
||||
|
||||
applyPlatformAndCoreConfiguration()
|
||||
applyCommonArtifactoryConfig()
|
||||
|
||||
dependencies {
|
||||
"api"(project(":nuvotifier-api"))
|
||||
|
||||
@@ -15,3 +15,6 @@ include("nuvotifier-sponge")
|
||||
project(":nuvotifier-sponge").projectDir = file("sponge")
|
||||
include("nuvotifier-velocity")
|
||||
project(":nuvotifier-velocity").projectDir = file("velocity")
|
||||
|
||||
include("nuvotifier-universal")
|
||||
project(":nuvotifier-universal").projectDir = file("universal")
|
||||
@@ -9,6 +9,7 @@ plugins {
|
||||
}
|
||||
|
||||
applyPlatformAndCoreConfiguration()
|
||||
applyCommonArtifactoryConfig()
|
||||
applyShadowConfiguration()
|
||||
|
||||
blossom {
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
|
||||
|
||||
plugins {
|
||||
`java-library`
|
||||
}
|
||||
|
||||
applyPlatformAndCoreConfiguration()
|
||||
applyShadowConfiguration()
|
||||
|
||||
configurations {
|
||||
compileClasspath.get().extendsFrom(create("shadeOnly"))
|
||||
}
|
||||
|
||||
dependencies {
|
||||
"implementation"(project(":nuvotifier-api"))
|
||||
"implementation"(project(":nuvotifier-common"))
|
||||
"implementation"(project(":nuvotifier-bukkit"))
|
||||
"implementation"(project(":nuvotifier-bungeecord"))
|
||||
"implementation"(project(":nuvotifier-sponge"))
|
||||
"implementation"(project(":nuvotifier-velocity"))
|
||||
}
|
||||
|
||||
tasks.named<Jar>("jar") {
|
||||
val projectVersion = project.version
|
||||
inputs.property("projectVersion", projectVersion)
|
||||
manifest {
|
||||
attributes("Implementation-Version" to projectVersion)
|
||||
}
|
||||
}
|
||||
|
||||
tasks.named<ShadowJar>("shadowJar") {
|
||||
configurations = listOf(project.configurations["shadeOnly"], project.configurations["runtimeClasspath"])
|
||||
|
||||
dependencies {
|
||||
include(dependency(":nuvotifier-api"))
|
||||
include(dependency(":nuvotifier-common"))
|
||||
include(dependency(":nuvotifier-bukkit"))
|
||||
include(dependency(":nuvotifier-bungeecord"))
|
||||
include(dependency(":nuvotifier-sponge"))
|
||||
include(dependency(":nuvotifier-velocity"))
|
||||
}
|
||||
|
||||
exclude("GradleStart**")
|
||||
exclude(".cache");
|
||||
exclude("LICENSE*")
|
||||
exclude("META-INF/services/**")
|
||||
exclude("META-INF/maven/**")
|
||||
exclude("META-INF/versions/**")
|
||||
exclude("org/intellij/**")
|
||||
exclude("org/jetbrains/**")
|
||||
exclude("**/module-info.class")
|
||||
}
|
||||
|
||||
tasks.named("assemble").configure {
|
||||
dependsOn("shadowJar")
|
||||
}
|
||||
@@ -6,6 +6,7 @@ plugins {
|
||||
}
|
||||
|
||||
applyPlatformAndCoreConfiguration()
|
||||
applyCommonArtifactoryConfig()
|
||||
applyShadowConfiguration()
|
||||
|
||||
blossom {
|
||||
|
||||
Reference in new issue
Block a user