Skip to content

Commit

Permalink
- test different conf for jitpack to create individual artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
rodvar committed Nov 7, 2024
1 parent 54e65fb commit 12964e4
Show file tree
Hide file tree
Showing 18 changed files with 18 additions and 35 deletions.
3 changes: 2 additions & 1 deletion account/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

version = rootProject.version

dependencies {
implementation(project(":i18n"))
implementation(project(":persistence"))
Expand Down
1 change: 0 additions & 1 deletion application/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
plugins {
id("bisq.java-library")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion bonded-roles/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,9 @@ class LocalMavenPublishPlugin : Plugin<Project> {
project.extensions.configure<PublishingExtension>("publishing") {
publications {
// val publicationName = if (group == DEFAULT_GROUP) "mavenJava" else "mavenJava_${group}"
val publicationName = "mavenJava"
create(publicationName, MavenPublication::class) {
var publicationName = "mavenJava"
var existingPublication = findByName(publicationName) ?: create(publicationName, MavenPublication::class)
(existingPublication as MavenPublication).apply {
from(project.components["java"]) // Adjust if publishing other types (like Kotlin)
artifactId = project.name
groupId = group
Expand All @@ -85,7 +86,9 @@ class LocalMavenPublishPlugin : Plugin<Project> {
setupPublication(project, group, protoSourcesJar)
}
if (group != DEFAULT_GROUP) {
create("mavenJava_bisqAlias", MavenPublication::class) {
publicationName = "mavenJava_bisqAlias"
existingPublication = findByName(publicationName) ?: create(publicationName, MavenPublication::class)
(existingPublication as MavenPublication).apply {
groupId = "bisq"
artifactId = project.name
version = rootVersion
Expand Down Expand Up @@ -146,12 +149,16 @@ class LocalMavenPublishPlugin : Plugin<Project> {
}

private fun loadRootVersion(project: Project) { val rootPropertiesFile = File(getRootGradlePropertiesFile(project), "gradle.properties")
val rootProperties = Properties()
if (rootPropertiesFile.exists()) {
rootProperties.load(rootPropertiesFile.inputStream())
}
if (project.version != "unspecified") {
rootVersion = project.version as String
} else {
val rootProperties = Properties()
if (rootPropertiesFile.exists()) {
rootProperties.load(rootPropertiesFile.inputStream())
}

rootVersion = rootProperties.getProperty("version", "unspecified")
rootVersion = rootProperties.getProperty("version", "unspecified")
}
}

private fun getRootGradlePropertiesFile(project: Project): File {
Expand Down
12 changes: 1 addition & 11 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,18 +1,8 @@
plugins {
java
id("maven-publish") // for jitpack
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

group = "bisq"
version = project.version
//sourceCompatibility = 1.8 // java 8
//targetCompatibility = 1.8

//java {
// withJavadocJar()
// withSourcesJar()
//}

tasks.register("buildAll") {
group = "build"
description = "Build the entire project leaving it ready to work with."
Expand Down
1 change: 0 additions & 1 deletion chat/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion common/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ plugins {
id("bisq.java-conventions")
id("bisq.java-integration-tests")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}


Expand Down
1 change: 0 additions & 1 deletion contract/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion i18n/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
plugins {
id("bisq.java-library")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}
1 change: 0 additions & 1 deletion identity/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion offer/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion persistence/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}
1 change: 0 additions & 1 deletion presentation/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion security/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion settings/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion support/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion trade/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down
1 change: 0 additions & 1 deletion user/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
plugins {
id("bisq.java-library")
id("bisq.protobuf")
id("bisq.gradle.maven_publisher.LocalMavenPublishPlugin")
}

dependencies {
Expand Down

0 comments on commit 12964e4

Please sign in to comment.