project: create poms when building, and utilize them in bootstrap. (#2259)
* project: create poms when building, and utilize them in bootstrap. * gradle: only publish during bootstrapping Co-authored-by: Owain van Brakel <owain.vanbrakel@gmail.com>
This commit is contained in:
@@ -92,22 +92,16 @@ subprojects {
|
||||
configure<PublishingExtension> {
|
||||
repositories {
|
||||
maven {
|
||||
name = "runelite"
|
||||
url = uri("https://maven.pkg.github.com/open-osrs/runelite")
|
||||
credentials {
|
||||
username = System.getProperty("gpr_user")
|
||||
password = System.getProperty("gpr_key")
|
||||
}
|
||||
url = uri("$buildDir/repo")
|
||||
}
|
||||
}
|
||||
publications {
|
||||
register("gpr", MavenPublication::class) {
|
||||
register("mavenJava", MavenPublication::class) {
|
||||
from(components["java"])
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
tasks {
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_11
|
||||
|
||||
@@ -31,6 +31,11 @@ class BootstrapPlugin : Plugin<Project> {
|
||||
tasks.withType<BootstrapTask> {
|
||||
dependsOn(bootstrapDependencies)
|
||||
|
||||
dependsOn(project(":runelite-api").tasks["publish"])
|
||||
dependsOn(project(":runescape-api").tasks["publish"])
|
||||
dependsOn(project(":http-api").tasks["publish"])
|
||||
dependsOn(project(":injected-client").tasks["publish"])
|
||||
|
||||
this.clientJar = clientJar.singleFile
|
||||
|
||||
doLast {
|
||||
@@ -38,6 +43,15 @@ class BootstrapPlugin : Plugin<Project> {
|
||||
from(bootstrapDependencies)
|
||||
into("${buildDir}/bootstrap/${type}/")
|
||||
}
|
||||
copy {
|
||||
from(
|
||||
"${parent?.projectDir}/runelite-client/build/repo/.",
|
||||
"${parent?.projectDir}/runelite-api/build/repo/.",
|
||||
"${parent?.projectDir}/http-api/build/repo/.",
|
||||
"${parent?.projectDir}/runescape-api/build/repo/."
|
||||
)
|
||||
into("${buildDir}/bootstrap/repo/")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,4 +36,4 @@ dependencies {
|
||||
implementation(Libraries.slf4jApi)
|
||||
|
||||
testImplementation(Libraries.junit)
|
||||
}
|
||||
}
|
||||
@@ -24,8 +24,8 @@
|
||||
*/
|
||||
|
||||
import org.apache.tools.ant.filters.ReplaceTokens
|
||||
import java.util.Date
|
||||
import java.text.SimpleDateFormat
|
||||
import java.util.*
|
||||
|
||||
plugins {
|
||||
id(Plugins.shadow.first) version Plugins.shadow.second
|
||||
|
||||
Reference in New Issue
Block a user