Skip to content

Commit

Permalink
feat: parallel build
Browse files Browse the repository at this point in the history
fix: version
  • Loading branch information
IWareQ committed Sep 12, 2024
1 parent 2953cbb commit 3c7127c
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 27 deletions.
2 changes: 1 addition & 1 deletion block-updater/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
group = "org.allaymc.updater.block"
version = "1.21.20"
version = "1.21.30"

dependencies {
api(project(":common"))
Expand Down
38 changes: 14 additions & 24 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
plugins {
id("java-library")
id("maven-publish")
id("signing")
}

subprojects {
apply(plugin = "java-library")
apply(plugin = "maven-publish")
apply(plugin = "signing")

group = "org.allaymc"
description = "Updates Minecraft: Bedrock Edition block & item states to the latest revision"

repositories {
Expand All @@ -36,24 +33,20 @@ subprojects {

publishing {
repositories {
maven {
name = "maven-deploy"
url = uri(
System.getenv("MAVEN_DEPLOY_URL")
?: "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/"
)
credentials {
username = System.getenv("MAVEN_DEPLOY_USERNAME") ?: "username"
password = System.getenv("MAVEN_DEPLOY_PASSWORD") ?: "password"
}
}
// Jitpack requires us to publish artifacts to local maven repo
mavenLocal()
}

publications {
create<MavenPublication>("maven") {
from(components["java"])

groupId = project.group.toString()
artifactId = project.name
version = project.version.toString()

pom {
inceptionYear.set("2022")
inceptionYear.set("2024")
packaging = "jar"
url.set("https://github.com/AllayMC/StateUpdater")

Expand Down Expand Up @@ -87,16 +80,13 @@ subprojects {
}
}

signing {
val secret = System.getenv("PGP_SECRET")
val passphrase = System.getenv("PGP_PASSPHRASE")
if (secret != null && passphrase != null) {
useInMemoryPgpKeys(secret, passphrase)
sign(publishing.publications["maven"])
tasks {
withType<JavaCompile> {
options.encoding = "UTF-8"
}
}

tasks.test {
useJUnitPlatform()
withType<Test> {
useJUnitPlatform()
}
}
}
6 changes: 5 additions & 1 deletion common/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
group = "org.allaymc.updater.common"
version = "1.0.0"
version = "1.0.0"

tasks.publish {
enabled = false
}
1 change: 1 addition & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
org.gradle.parallel=true
2 changes: 1 addition & 1 deletion item-updater/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
group = "org.allaymc.updater.item"
version = "1.21.20"
version = "1.21.30"

dependencies {
api(project(":common"))
Expand Down

0 comments on commit 3c7127c

Please sign in to comment.