Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions bom/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
/*
* Copyright 2026 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

plugins {
id("android.maps.utils.BomPublishingConventionPlugin")
}

dependencies {
constraints {
api(project(":clustering"))
api(project(":data"))
api(project(":heatmaps"))
api(project(":library"))
api(project(":onion"))
api(project(":ui"))
api(project(":visual-testing"))
}
}
4 changes: 4 additions & 0 deletions build-logic/convention/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,9 @@ gradlePlugin {
id = "android.maps.utils.PublishingConventionPlugin"
implementationClass = "PublishingConventionPlugin"
}
register("bomPublishingConventionPlugin") {
id = "android.maps.utils.BomPublishingConventionPlugin"
implementationClass = "BomPublishingConventionPlugin"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
/*
* Copyright 2026 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

import com.vanniktech.maven.publish.MavenPublishBaseExtension
import org.gradle.api.Plugin
import org.gradle.api.Project
import org.gradle.kotlin.dsl.*

class BomPublishingConventionPlugin : Plugin<Project> {
override fun apply(project: Project) {
project.run {
apply(plugin = "java-platform")
apply(plugin = "com.vanniktech.maven.publish")

extensions.configure<MavenPublishBaseExtension> {
publishToMavenCentral()
signAllPublications()

coordinates(
artifactId = "maps-utils-bom",
)

pom {
name.set("android-maps-utils-bom")
description.set("BoM for android-maps-utils")
url.set("https://github.com/googlemaps/android-maps-utils")
licenses {
license {
name.set("The Apache Software License, Version 2.0")
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
distribution.set("repo")
}
}
scm {
connection.set("scm:git@github.com:googlemaps/android-maps-utils.git")
developerConnection.set("scm:git@github.com:googlemaps/android-maps-utils.git")
url.set("https://github.com/googlemaps/android-maps-utils")
}
developers {
developer {
id.set("google")
name.set("Google LLC")
}
}
organization {
name.set("Google Inc")
url.set("http://developers.google.com/maps")
}
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,13 @@ class PublishingConventionPlugin : Plugin<Project> {
publishToMavenCentral()
signAllPublications()

val artifactName = if (project.name == "library") {
"android-maps-utils"
} else {
"maps-utils-${project.name}"
}
coordinates(
artifactId = "android-maps-utils",
artifactId = artifactName,
)

pom {
Expand Down
2 changes: 1 addition & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ pluginManagement {
}
}

include("demo", "clustering", "heatmaps", "ui", "data", "lint-checks", "library", "onion", "visual-testing")
include("demo", "clustering", "heatmaps", "ui", "data", "lint-checks", "library", "onion", "visual-testing", "bom")