Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
f31cd59
migrated sv build architecture for toolkit project
shubham7109 Aug 13, 2025
8336077
Add all Toolkit convention migration changes
shubham7109 Aug 18, 2025
4d3079b
Abstract ArcGISMapsKotlinSDK dependency as a gradle object
shubham7109 Aug 18, 2025
e6c8f6b
Untangle dependencies and add PR feedback
shubham7109 Aug 19, 2025
4937ba9
vTest build fixes
shubham7109 Aug 19, 2025
95b23fc
Add automatic detection of androidTest sources
shubham7109 Aug 19, 2025
483cabb
working changes
shubham7109 Sep 14, 2025
ae445df
Merge branch 'v.next' into shubham/migrate-convention-plugins
shubham7109 Sep 18, 2025
af0dde4
Add v.next build fixes
shubham7109 Sep 18, 2025
fb8710e
add Toolkit version provider and module registry
shubham7109 Sep 24, 2025
bc6c542
Merge branch 'v.next' into shubham/migrate-convention-plugins
shubham7109 Sep 24, 2025
db71c5f
update toml, add root convention
shubham7109 Sep 25, 2025
9794995
Merge branch 'v.next' into shubham/migrate-convention-plugins
shubham7109 Sep 25, 2025
7621495
fix freeCompilerArgs warnings
shubham7109 Sep 25, 2025
d8eda36
Add MissingTranslation for popup
shubham7109 Sep 25, 2025
0b2ca36
Merge branch 'v.next' into toolkit/migrate-convention-plugins
shubham7109 Sep 26, 2025
4530c5f
Merge branch 'toolkit/migrate-convention-plugins' into shubham/migrat…
shubham7109 Sep 26, 2025
ea471ff
Migrate toolkit registry as a gradle service
shubham7109 Sep 29, 2025
edb7cc7
use expected gradle properties
shubham7109 Sep 29, 2025
04cacf5
add copyrights
shubham7109 Sep 30, 2025
7560805
Merge branch 'v.next' into shubham/migrate-convention-plugins
shubham7109 Oct 3, 2025
6879a2c
Supply mockingjay for lib androidTestImplementation
shubham7109 Oct 3, 2025
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
6 changes: 2 additions & 4 deletions bom/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
*/

plugins {
id("maven-publish")
id("java-platform")
`maven-publish`
`java-platform`
}

// Find these in properties passed through command line or read from GRADLE_HOME/gradle.properties
Expand Down Expand Up @@ -91,5 +91,3 @@ afterEvaluate {
}
}
}


Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
import com.android.build.api.dsl.ApplicationExtension
import com.esri.arcgismaps.kotlin.build_logic.convention.configureAndroidCompose
import com.esri.arcgismaps.kotlin.build_logic.convention.configureKotlinAndroid
import com.esri.arcgismaps.kotlin.build_logic.convention.debugImplementation
import com.esri.arcgismaps.kotlin.build_logic.convention.implementation
import com.esri.arcgismaps.kotlin.build_logic.convention.libs
import com.esri.arcgismaps.kotlin.build_logic.convention.testImplementation
import com.esri.arcgismaps.kotlin.build_logic.convention.androidTestImplementation
import com.esri.arcgismaps.kotlin.build_logic.convention.debugImplementation
import org.gradle.api.Plugin
import org.gradle.api.Project
import org.gradle.kotlin.dsl.dependencies
Expand All @@ -22,18 +20,14 @@ class AndroidApplicationComposeConventionPlugin : Plugin<Project> {
val extension = extensions.getByType<ApplicationExtension>()
configureKotlinAndroid(extension)
configureAndroidCompose(extension)

// Add common Compose dependencies for application modules
dependencies {
implementation(platform(libs.findLibrary("androidx-compose-bom").get()))
implementation(libs.findBundle("composeCore").get())
implementation(libs.findBundle("core").get())
implementation(libs.findLibrary("androidx-activity-compose").get())
implementation(libs.findLibrary("androidx-lifecycle-viewmodel-compose").get())

testImplementation(libs.findBundle("unitTest").get())
androidTestImplementation(platform(libs.findLibrary("androidx-compose-bom").get()))
androidTestImplementation(libs.findBundle("composeTest").get())
debugImplementation(libs.findBundle("debug").get())
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class AndroidLibraryComposeConventionPlugin : Plugin<Project> {
val extension = extensions.getByType<LibraryExtension>()
configureKotlinAndroid(extension)
configureAndroidCompose(extension)

// Add common Compose dependencies for library modules
dependencies {
implementation(platform(libs.findLibrary("androidx-compose-bom").get()))
Expand All @@ -33,11 +33,10 @@ class AndroidLibraryComposeConventionPlugin : Plugin<Project> {
implementation(libs.findLibrary("androidx-lifecycle-runtime-compose").get())
implementation(libs.findLibrary("androidx-activity-compose").get())
implementation(libs.findLibrary("androidx-material-icons").get())

implementation(libs.findLibrary("kotlinx-serialization-json").get())

testImplementation(libs.findBundle("unitTest").get())
androidTestImplementation(libs.findBundle("composeTest").get())
androidTestImplementation(libs.findBundle("androidXTest").get())
debugImplementation(libs.findBundle("debug").get())
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@ class ArcGISMapsKotlinToolkitConventionPlugin : Plugin<Project> {
with(pluginManager) {
apply(libs.findPlugin("arcgismaps-android-library").get().get().pluginId)
apply(libs.findPlugin("arcgismaps-android-library-compose").get().get().pluginId)
apply(libs.findPlugin("binary-compatibility-validator").get().get().pluginId)
// Only apply binary compatibility validator if shouldValidateApi is true
val shouldValidateApi = target.findProperty("shouldValidateApi") as? Boolean ?: true
if (shouldValidateApi){
apply(libs.findPlugin("binary-compatibility-validator").get().get().pluginId)
}
}

extensions.configure<LibraryExtension> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@ internal fun Project.configureAndroidCompose(
implementation(libs.findLibrary("androidx-compose-material3").get())
implementation(libs.findLibrary("androidx-lifecycle-viewmodel-compose").get())
implementation(libs.findLibrary("androidx-compose-ui-tooling-preview").get())
debugImplementation(libs.findLibrary("androidx-compose-ui-tooling").get())
debugImplementation(libs.findLibrary("androidx-compose-ui-test-manifest").get())
debugImplementation(libs.findBundle("debug").get())
androidTestImplementation(libs.findLibrary("androidx-compose-ui-test").get())
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ object ArcGISMapsKotlinSDKDependency {
*/
fun configureArcGISMapsDependencies(target: Project) {
target.dependencies {
// For finalBuilds ignore the build number and pick up the released version of the SDK dependency
val finalBuild: Boolean = (target.providers.gradleProperty("finalBuild").orNull ?: "false")
.toBoolean()

// First look for the version number provided via command line (for CI builds), if not found,
// take the one defined in gradle.properties.
// CI builds pass -PversionNumber=${BUILDVER}
Expand All @@ -40,16 +44,21 @@ object ArcGISMapsKotlinSDKDependency {

// ArcGIS Maps SDK dependency with build override support
if (sdkVersionNumber != null) {
// If a buildNumber is provided and not blank, append it to the version.
val dependencyVersion = if (!sdkBuildNumber.isNullOrBlank()) {
"$sdkVersionNumber-$sdkBuildNumber"
} else {
val dependencyVersion = if (finalBuild) {
// For a final build, use the version number directly
sdkVersionNumber
} else {
// If a buildNumber is provided and not blank, append it to the version.
if (!sdkBuildNumber.isNullOrBlank()) {
"$sdkVersionNumber-$sdkBuildNumber"
} else {
sdkVersionNumber
}
}
implementation("com.esri:arcgis-maps-kotlin:$dependencyVersion")
api("com.esri:arcgis-maps-kotlin:$dependencyVersion")
} else {
// Use libs.versions.toml if no gradle property is provided
implementation(target.libs.findLibrary("arcgis-maps-kotlin").get())
api(target.libs.findLibrary("arcgis-maps-kotlin").get())
}
}
}
Expand Down
18 changes: 17 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,23 @@ testAggregation {
}
}

/**
* Excludes specific modules from the 'apiDump' task.
* Add all modules to be excluded to the `excludedFromApiDump` set.
*/
subprojects {
// Define the modules to be excluded from apiDump
val excludedFromApiDump = setOf(
"bom",
"kdoc",
"template",
"microapps-lib",
"composable-map"
)
// Add this property to indicate whether this project should have API validation
ext.set("shouldValidateApi", project.name !in excludedFromApiDump)
}

/**
* Returns all modules in this project, except the ones specified by [modulesToExclude].
*/
Expand All @@ -132,4 +149,3 @@ fun getModulesExcept(vararg modulesToExclude: String): List<String> =
}
.filter { !modulesToExclude.contains(it) } // exclude specified modules
}

4 changes: 2 additions & 2 deletions gradle-plugins/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ gradlePlugin {
group = "internal"
id = "artifact-deploy"
version = "1.0"
implementationClass = "deploy.ArtifactPublisher"
implementationClass = "com.arcgismaps.ArtifactPublisher"
}
}
}

dependencies {
implementation(libs.kotlinx.serialization.json)
// Module-specific dependencies go here
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,13 @@
*
*/

package deploy
package com.arcgismaps

import org.gradle.api.Plugin
import org.gradle.api.Project
import org.gradle.api.publish.PublishingExtension
import org.gradle.api.publish.maven.MavenPublication
import org.gradle.api.publish.maven.plugins.MavenPublishPlugin
import org.gradle.configurationcache.extensions.capitalized
import org.gradle.kotlin.dsl.configure
import org.gradle.kotlin.dsl.get
import org.gradle.kotlin.dsl.provideDelegate
Expand Down Expand Up @@ -55,8 +54,8 @@ class ArtifactPublisher : Plugin<Project> {
} else {
"$versionNumber-$buildNumber"
}
val artifactoryArtifactId: String = "$artifactoryArtifactBaseId-${project.name}"
val artifactoryArtifactId = "$artifactoryArtifactBaseId-${project.name}"

project.pluginManager.apply(MavenPublishPlugin::class.java)
project.afterEvaluate {
project.extensions.configure<PublishingExtension> {
Expand All @@ -77,7 +76,7 @@ class ArtifactPublisher : Plugin<Project> {
groupId = artifactoryGroupId
artifactId = artifactoryArtifactId
version = artifactVersion

from(project.components["release"])
}
}
Expand Down
5 changes: 0 additions & 5 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ arcgisMapsKotlinVersion = "300.0.0-4695"
androidGradlePlugin = "8.9.2"
androidXBrowser = "1.8.0"
androidxCamera = "1.4.2"
androidxComposeCompiler = "1.5.12"
androidxCore = "1.16.0"
androidxEspresso = "3.6.1"
androidxHiltNavigationCompose = "1.2.0"
Expand Down Expand Up @@ -79,7 +78,6 @@ play-services-location = { group = "com.google.android.gms", name = "play-servic
### Kotlin libs
kotlin-reflect = { group = "org.jetbrains.kotlin", name = "kotlin-reflect", version.ref = "kotlin"}
kotlinx-coroutines-test = { group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-test", version.ref = "kotlinxCoroutinesTest" }
kotlinx-serialization-core = { group = "org.jetbrains.kotlinx", name = "kotlinx-serialization-core", version.ref = "kotlinxSerializationJson" }
kotlinx-serialization-json = { group = "org.jetbrains.kotlinx", name = "kotlinx-serialization-json", version.ref = "kotlinxSerializationJson" }

### Compose libs
Expand Down Expand Up @@ -112,16 +110,13 @@ truth = { group = "com.google.truth", name = "truth", version.ref = "truth" }

### Third party libs
coil = { group = "io.coil-kt", name = "coil" }
coil-base = { group = "io.coil-kt", name = "coil-base" }
coil-bom = { group = "io.coil-kt", name = "coil-bom", version.ref = "coilBOM" }
coil-compose = { group = "io.coil-kt", name = "coil-compose" }
commonmark = { group = "org.commonmark", name = "commonmark", version.ref="commonMark" }
commonmark-strikethrough = { group = "org.commonmark", name = "commonmark-ext-gfm-strikethrough", version.ref="commonMark" }
dokka-versioning = { group = "org.jetbrains.dokka", name = "versioning-plugin", version.ref = "dokka" }
hilt-android-core = { group = "com.google.dagger", name = "hilt-android", version.ref = "hilt" }
hilt-compiler = { group = "com.google.dagger", name = "hilt-android-compiler", version.ref = "hilt" }
hilt-ext-compiler = { group = "androidx.hilt", name = "hilt-compiler", version.ref = "hiltExt" }
hilt-ext-work = { group = "androidx.hilt", name = "hilt-work", version.ref = "hiltExt" }
room-compiler = { group = "androidx.room", name = "room-compiler", version.ref = "room" }
room-ext = { group = "androidx.room", name = "room-ktx", version.ref = "room" }
room-runtime = { group = "androidx.room", name = "room-runtime", version.ref = "room" }
Expand Down
12 changes: 3 additions & 9 deletions kdoc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,9 @@
*/

plugins {
alias(libs.plugins.android.library)
alias(libs.plugins.kotlin.android)
alias(libs.plugins.dokka)
// put exposed dependencies in dokka's classpath
alias(libs.plugins.arcgismaps.kotlin.toolkit)
// put exposed dependencies in dokka's classpath
alias(libs.plugins.arcgismaps.kotlin.sdk)
}

Expand Down Expand Up @@ -69,7 +67,7 @@ tasks {
matchingRegex.set(".*internal.*")
suppress.set(true)
}

perPackageOption {
reportUndocumented.set(true)
}
Expand All @@ -81,7 +79,7 @@ tasks {
android {
namespace = "com.arcgismaps.toolkit.doc"
compileSdk = libs.versions.compileSdk.get().toInt()

defaultConfig {
minSdk = libs.versions.minSdk.get().toInt()
consumerProguardFiles("consumer-rules.pro")
Expand All @@ -91,8 +89,4 @@ android {
dependencies {
// Puts the version in the KDoc
dokkaPlugin(libs.dokka.versioning)
// put exposed dependencies in dokka's classpath
implementation(platform(libs.androidx.compose.bom))
implementation(libs.bundles.composeCore)
}

6 changes: 0 additions & 6 deletions microapps/MicroappsLib/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,4 @@ android {

dependencies {
// Module-specific dependencies go here
implementation(platform(libs.androidx.compose.bom))
implementation(libs.bundles.composeCore)
implementation(libs.bundles.core)
implementation(libs.androidx.lifecycle.runtime.compose)
implementation(libs.androidx.activity.compose)
debugImplementation(libs.bundles.debug)
}
Loading