From 76fce78117fd6125e89ea90917730b3e5422c55a Mon Sep 17 00:00:00 2001 From: Andrew Reed Date: Wed, 13 Aug 2025 10:45:31 +0100 Subject: [PATCH 1/3] Update publishing configuration for Maven Central --- .github/workflows/publish.yml | 8 ++++---- build.gradle.kts | 11 +---------- firebase-analytics/build.gradle.kts | 15 ++++++++++----- firebase-analytics/package.json | 4 ++-- firebase-app/build.gradle.kts | 15 ++++++++++----- firebase-app/package.json | 4 ++-- firebase-auth/build.gradle.kts | 15 ++++++++++----- firebase-auth/package.json | 4 ++-- firebase-common-internal/build.gradle.kts | 15 ++++++++++----- firebase-common-internal/package.json | 4 ++-- firebase-common/build.gradle.kts | 16 ++++++++++------ firebase-common/package.json | 2 +- firebase-config/build.gradle.kts | 15 ++++++++++----- firebase-config/package.json | 4 ++-- firebase-crashlytics/build.gradle.kts | 15 ++++++++++----- firebase-crashlytics/package.json | 4 ++-- firebase-database/build.gradle.kts | 15 ++++++++++----- firebase-database/package.json | 4 ++-- firebase-firestore/build.gradle.kts | 17 +++++++++++------ firebase-firestore/package.json | 4 ++-- firebase-functions/build.gradle.kts | 15 ++++++++++----- firebase-functions/package.json | 4 ++-- firebase-installations/build.gradle.kts | 15 ++++++++++----- firebase-installations/package.json | 4 ++-- firebase-messaging/build.gradle.kts | 15 ++++++++++----- firebase-messaging/package.json | 4 ++-- firebase-perf/build.gradle.kts | 15 ++++++++++----- firebase-perf/package.json | 4 ++-- firebase-storage/build.gradle.kts | 15 ++++++++++----- firebase-storage/package.json | 4 ++-- gradle/libs.versions.toml | 2 ++ 31 files changed, 175 insertions(+), 113 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 9d07e7715..6df49ac89 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -8,10 +8,10 @@ on: types: [ prereleased, released ] env: - sonatypeUsername: ${{ secrets.SONATYPEUSERNAME }} - sonatypePassword: ${{ secrets.SONATYPEPASSWORD }} - ORG_GRADLE_PROJECT_signingKey: ${{ secrets.GPG_PRIVATE_KEY }} - ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.PASSPHRASE }} + ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPEUSERNAME }} + ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.SONATYPEPASSWORD }} + ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.GPG_PRIVATE_KEY }} + ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.PASSPHRASE }} jobs: build: diff --git a/build.gradle.kts b/build.gradle.kts index 616056734..c54554686 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,6 +19,7 @@ plugins { alias(libs.plugins.kotlinter) apply false alias(libs.plugins.kotlinx.binarycompatibilityvalidator) alias(libs.plugins.dokka) + alias(libs.plugins.publish) apply false id("base") id("testOptionsConvention") } @@ -194,16 +195,6 @@ subprojects { configure { - repositories { - maven { - url = uri("https://central.sonatype.com/repository/maven-snapshots") - credentials { - username = project.findProperty("sonatypeUsername") as String? ?: System.getenv("sonatypeUsername") - password = project.findProperty("sonatypePassword") as String? ?: System.getenv("sonatypePassword") - } - } - } - publications.all { this as MavenPublication artifact(javadocJar) diff --git a/firebase-analytics/build.gradle.kts b/firebase-analytics/build.gradle.kts index 9a2086d51..1a541ece6 100644 --- a/firebase-analytics/build.gradle.kts +++ b/firebase-analytics/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("native.cocoapods") kotlin("multiplatform") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -160,9 +161,13 @@ if (project.property("firebase-analytics.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-analytics", + version = project.property("firebase-analytics.version") as String + ) } diff --git a/firebase-analytics/package.json b/firebase-analytics/package.json index 047cf14c4..5d9745c01 100644 --- a/firebase-analytics/package.json +++ b/firebase-analytics/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-analytics", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-analytics.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.6.10", "kotlinx-coroutines-core": "1.6.1-native-mt" diff --git a/firebase-app/build.gradle.kts b/firebase-app/build.gradle.kts index 72b67d8a3..8acd39244 100644 --- a/firebase-app/build.gradle.kts +++ b/firebase-app/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("native.cocoapods") kotlin("multiplatform") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -165,9 +166,13 @@ if (project.property("firebase-app.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-app", + version = project.property("firebase-app.version") as String + ) } diff --git a/firebase-app/package.json b/firebase-app/package.json index 6bad942eb..00f449585 100644 --- a/firebase-app/package.json +++ b/firebase-app/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-app", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-app.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-common": "2.1.0", + "@gitlive/firebase-common": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-auth/build.gradle.kts b/firebase-auth/build.gradle.kts index 7a0d0adec..df761cd6f 100644 --- a/firebase-auth/build.gradle.kts +++ b/firebase-auth/build.gradle.kts @@ -16,6 +16,7 @@ plugins { kotlin("multiplatform") kotlin("native.cocoapods") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -186,9 +187,13 @@ fun KotlinNativeTargetWithSimulatorTests.enableKeychainForTests() { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-auth", + version = project.property("firebase-auth.version") as String + ) } diff --git a/firebase-auth/package.json b/firebase-auth/package.json index 5a2fe936b..86b44cc7d 100644 --- a/firebase-auth/package.json +++ b/firebase-auth/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-auth", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-auth.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-common-internal/build.gradle.kts b/firebase-common-internal/build.gradle.kts index 9d6067d7a..88ae77ee1 100644 --- a/firebase-common-internal/build.gradle.kts +++ b/firebase-common-internal/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("multiplatform") kotlin("plugin.serialization") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -167,10 +168,14 @@ if (project.property("firebase-common.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-common-internal", + version = project.property("firebase-common-internal.version") as String + ) } diff --git a/firebase-common-internal/package.json b/firebase-common-internal/package.json index 9548da6c3..b91a10d69 100644 --- a/firebase-common-internal/package.json +++ b/firebase-common-internal/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-common-internal", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-common-internal.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-multiplatform-sdk", "dependencies": { - "@gitlive/firebase-common": "2.1.0", + "@gitlive/firebase-common": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4", diff --git a/firebase-common/build.gradle.kts b/firebase-common/build.gradle.kts index 82b6cab2e..74359590f 100644 --- a/firebase-common/build.gradle.kts +++ b/firebase-common/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("multiplatform") kotlin("plugin.serialization") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -165,10 +166,13 @@ if (project.property("firebase-common.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) -} +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-common", + version = project.property("firebase-common.version") as String + ) +} diff --git a/firebase-common/package.json b/firebase-common/package.json index 61f1c13d0..201fa39df 100644 --- a/firebase-common/package.json +++ b/firebase-common/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-common", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-common.js", "scripts": { diff --git a/firebase-config/build.gradle.kts b/firebase-config/build.gradle.kts index fa7cee1ec..2a4f726b6 100644 --- a/firebase-config/build.gradle.kts +++ b/firebase-config/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("multiplatform") kotlin("native.cocoapods") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -160,9 +161,13 @@ if (project.property("firebase-config.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-config", + version = project.property("firebase-config.version") as String + ) } diff --git a/firebase-config/package.json b/firebase-config/package.json index e8684ce16..13cdb9d60 100644 --- a/firebase-config/package.json +++ b/firebase-config/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-config", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-config.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-crashlytics/build.gradle.kts b/firebase-crashlytics/build.gradle.kts index 189fb6833..aa34f8233 100644 --- a/firebase-crashlytics/build.gradle.kts +++ b/firebase-crashlytics/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("multiplatform") kotlin("native.cocoapods") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -147,9 +148,13 @@ if (project.property("firebase-crashlytics.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-crashlytics", + version = project.property("firebase-crashlytics.version") as String + ) } diff --git a/firebase-crashlytics/package.json b/firebase-crashlytics/package.json index 77903f7d4..73fb722bf 100644 --- a/firebase-crashlytics/package.json +++ b/firebase-crashlytics/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-crashlytics", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-crashlytics.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.6.10", "kotlinx-coroutines-core": "1.6.1-native-mt" diff --git a/firebase-database/build.gradle.kts b/firebase-database/build.gradle.kts index 5914d2f67..4d1f354f7 100644 --- a/firebase-database/build.gradle.kts +++ b/firebase-database/build.gradle.kts @@ -15,6 +15,7 @@ plugins { kotlin("multiplatform") kotlin("plugin.serialization") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -173,9 +174,13 @@ if (project.property("firebase-database.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-database", + version = project.property("firebase-database.version") as String + ) } diff --git a/firebase-database/package.json b/firebase-database/package.json index 7ed7fb0b2..307cda191 100644 --- a/firebase-database/package.json +++ b/firebase-database/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-database", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-database.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-firestore/build.gradle.kts b/firebase-firestore/build.gradle.kts index be2161656..7ed0ae7ca 100644 --- a/firebase-firestore/build.gradle.kts +++ b/firebase-firestore/build.gradle.kts @@ -15,6 +15,7 @@ plugins { kotlin("multiplatform") kotlin("plugin.serialization") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -189,9 +190,13 @@ if (project.property("firebase-firestore.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) -} \ No newline at end of file +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-firestore", + version = project.property("firebase-firestore.version") as String + ) +} diff --git a/firebase-firestore/package.json b/firebase-firestore/package.json index 50c424548..ad5995908 100644 --- a/firebase-firestore/package.json +++ b/firebase-firestore/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-firestore", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-firestore.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-functions/build.gradle.kts b/firebase-functions/build.gradle.kts index 3a704ef56..88c813863 100644 --- a/firebase-functions/build.gradle.kts +++ b/firebase-functions/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("native.cocoapods") kotlin("multiplatform") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -168,9 +169,13 @@ if (project.property("firebase-functions.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-functions", + version = project.property("firebase-functions.version") as String + ) } diff --git a/firebase-functions/package.json b/firebase-functions/package.json index 81ab98572..e892d87c6 100644 --- a/firebase-functions/package.json +++ b/firebase-functions/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-functions", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-functions.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-installations/build.gradle.kts b/firebase-installations/build.gradle.kts index 2017b1c56..8f94cc386 100644 --- a/firebase-installations/build.gradle.kts +++ b/firebase-installations/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("native.cocoapods") kotlin("multiplatform") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -164,9 +165,13 @@ if (project.property("firebase-installations.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-installations", + version = project.property("firebase-installations.version") as String + ) } diff --git a/firebase-installations/package.json b/firebase-installations/package.json index 0f9ebb653..9bdad14e1 100644 --- a/firebase-installations/package.json +++ b/firebase-installations/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-installations", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-installations.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-messaging/build.gradle.kts b/firebase-messaging/build.gradle.kts index 52ac31e32..04887e49b 100644 --- a/firebase-messaging/build.gradle.kts +++ b/firebase-messaging/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("multiplatform") kotlin("native.cocoapods") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -162,9 +163,13 @@ if (project.property("firebase-messaging.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-messaging", + version = project.property("firebase-messaging.version") as String + ) } diff --git a/firebase-messaging/package.json b/firebase-messaging/package.json index 40ddedd6e..abb906683 100644 --- a/firebase-messaging/package.json +++ b/firebase-messaging/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-messaging", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-messaging.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.8.20", "kotlinx-coroutines-core": "1.6.4" diff --git a/firebase-perf/build.gradle.kts b/firebase-perf/build.gradle.kts index 840ff5f0e..188b7b5ef 100644 --- a/firebase-perf/build.gradle.kts +++ b/firebase-perf/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("multiplatform") kotlin("native.cocoapods") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -159,9 +160,13 @@ if (project.property("firebase-perf.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-perf", + version = project.property("firebase-perf.version") as String + ) } diff --git a/firebase-perf/package.json b/firebase-perf/package.json index 4efea2201..3f1fbab22 100644 --- a/firebase-perf/package.json +++ b/firebase-perf/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-perf", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-perf.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.6.10", "kotlinx-coroutines-core": "1.6.1-native-mt" diff --git a/firebase-storage/build.gradle.kts b/firebase-storage/build.gradle.kts index 3bfd22634..cc46955c3 100644 --- a/firebase-storage/build.gradle.kts +++ b/firebase-storage/build.gradle.kts @@ -14,6 +14,7 @@ plugins { kotlin("native.cocoapods") kotlin("multiplatform") id("testOptionsConvention") + alias(libs.plugins.publish) } android { @@ -160,9 +161,13 @@ if (project.property("firebase-storage.skipJsTests") == "true") { } } -signing { - val signingKey: String? by project - val signingPassword: String? by project - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications) +mavenPublishing { + publishToMavenCentral(automaticRelease = true) + signAllPublications() + + coordinates( + groupId = "dev.gitlive", + artifactId = "firebase-storage", + version = project.property("firebase-storage.version") as String + ) } diff --git a/firebase-storage/package.json b/firebase-storage/package.json index 8d6168aab..e791958c2 100644 --- a/firebase-storage/package.json +++ b/firebase-storage/package.json @@ -1,6 +1,6 @@ { "name": "@gitlive/firebase-storage", - "version": "2.1.0", + "version": "2.2.0", "description": "Wrapper around firebase for usage in Kotlin Multiplatform projects", "main": "firebase-storage.js", "scripts": { @@ -23,7 +23,7 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { - "@gitlive/firebase-app": "2.1.0", + "@gitlive/firebase-app": "2.2.0", "firebase": "9.19.1", "kotlin": "1.6.10", "kotlinx-coroutines-core": "1.6.1-native-mt" diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index a79b72942..3c9b017e1 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -20,6 +20,7 @@ firebase-cocoapods = "11.4.0" ios-deploymentTarget = "13.0" test-logger-plugin = "4.0.0" dokka = "2.0.0" +publish = "0.34.0" [libraries] android-gradle-plugin = { module = "com.android.tools.build:gradle", version.ref = "agp" } @@ -60,3 +61,4 @@ native-cocoapods = { id = "org.jetbrains.kotlin.native.cocoapods", version.ref = test-logger-plugin = { id = "com.adarshr.test-logger", version.ref = "test-logger-plugin" } dokka = { id = "org.jetbrains.dokka", version.ref = "dokka" } kotlinter = { id = "org.jmailen.kotlinter", version.ref = "kotlinter" } +publish = { id = "com.vanniktech.maven.publish", version.ref = "publish" } From 9cfd1bf4f27d01de4f25dbf2d873f51f89f0779c Mon Sep 17 00:00:00 2001 From: Andrew Reed Date: Thu, 14 Aug 2025 08:58:25 +0100 Subject: [PATCH 2/3] Moved pom details into individual build files --- build.gradle.kts | 52 ----------------------- firebase-analytics/build.gradle.kts | 37 ++++++++++++++++ firebase-app/build.gradle.kts | 37 ++++++++++++++++ firebase-auth/build.gradle.kts | 37 ++++++++++++++++ firebase-common-internal/build.gradle.kts | 37 ++++++++++++++++ firebase-common/build.gradle.kts | 37 ++++++++++++++++ firebase-config/build.gradle.kts | 37 ++++++++++++++++ firebase-crashlytics/build.gradle.kts | 37 ++++++++++++++++ firebase-database/build.gradle.kts | 37 ++++++++++++++++ firebase-firestore/build.gradle.kts | 37 ++++++++++++++++ firebase-functions/build.gradle.kts | 37 ++++++++++++++++ firebase-installations/build.gradle.kts | 37 ++++++++++++++++ firebase-messaging/build.gradle.kts | 37 ++++++++++++++++ firebase-perf/build.gradle.kts | 37 ++++++++++++++++ firebase-storage/build.gradle.kts | 37 ++++++++++++++++ 15 files changed, 518 insertions(+), 52 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index c54554686..f78a4b8ae 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -188,58 +188,6 @@ subprojects { apply(plugin = "maven-publish") apply(plugin = "signing") - - val javadocJar: TaskProvider by tasks.registering(Jar::class) { - archiveClassifier.set("javadoc") - } - - configure { - - publications.all { - this as MavenPublication - artifact(javadocJar) - - pom { - name.set("firebase-kotlin-sdk") - description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") - url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") - inceptionYear.set("2019") - - scm { - url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") - connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") - developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") - tag.set("HEAD") - } - - issueManagement { - system.set("GitHub Issues") - url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") - } - - developers { - developer { - name.set("Nicholas Bransby-Williams") - email.set("nbransby@gmail.com") - } - } - - 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") - comments.set("A business-friendly OSS license") - } - } - } - } - - } - - tasks.withType(AbstractPublishToMaven::class.java).configureEach { - dependsOn(tasks.withType(Sign::class.java)) - } } tasks.withType { diff --git a/firebase-analytics/build.gradle.kts b/firebase-analytics/build.gradle.kts index 1a541ece6..11d6d2cf0 100644 --- a/firebase-analytics/build.gradle.kts +++ b/firebase-analytics/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2023 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -170,4 +172,39 @@ mavenPublishing { artifactId = "firebase-analytics", version = project.property("firebase-analytics.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-app/build.gradle.kts b/firebase-app/build.gradle.kts index 8acd39244..99e9c95a2 100644 --- a/firebase-app/build.gradle.kts +++ b/firebase-app/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -175,4 +177,39 @@ mavenPublishing { artifactId = "firebase-app", version = project.property("firebase-app.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-auth/build.gradle.kts b/firebase-auth/build.gradle.kts index df761cd6f..ed1a7647e 100644 --- a/firebase-auth/build.gradle.kts +++ b/firebase-auth/build.gradle.kts @@ -1,9 +1,11 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree import org.jetbrains.kotlin.gradle.plugin.mpp.KotlinNativeTargetWithSimulatorTests import org.jetbrains.kotlin.gradle.targets.native.tasks.KotlinNativeSimulatorTest +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -196,4 +198,39 @@ mavenPublishing { artifactId = "firebase-auth", version = project.property("firebase-auth.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-common-internal/build.gradle.kts b/firebase-common-internal/build.gradle.kts index 88ae77ee1..97549c2fe 100644 --- a/firebase-common-internal/build.gradle.kts +++ b/firebase-common-internal/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -177,5 +179,40 @@ mavenPublishing { artifactId = "firebase-common-internal", version = project.property("firebase-common-internal.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-common/build.gradle.kts b/firebase-common/build.gradle.kts index 74359590f..07ec4b0ce 100644 --- a/firebase-common/build.gradle.kts +++ b/firebase-common/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -175,4 +177,39 @@ mavenPublishing { artifactId = "firebase-common", version = project.property("firebase-common.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-config/build.gradle.kts b/firebase-config/build.gradle.kts index 2a4f726b6..b47b8deb5 100644 --- a/firebase-config/build.gradle.kts +++ b/firebase-config/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -170,4 +172,39 @@ mavenPublishing { artifactId = "firebase-config", version = project.property("firebase-config.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-crashlytics/build.gradle.kts b/firebase-crashlytics/build.gradle.kts index aa34f8233..514c1763b 100644 --- a/firebase-crashlytics/build.gradle.kts +++ b/firebase-crashlytics/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -157,4 +159,39 @@ mavenPublishing { artifactId = "firebase-crashlytics", version = project.property("firebase-crashlytics.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-database/build.gradle.kts b/firebase-database/build.gradle.kts index 4d1f354f7..6f64bddb6 100644 --- a/firebase-database/build.gradle.kts +++ b/firebase-database/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -183,4 +185,39 @@ mavenPublishing { artifactId = "firebase-database", version = project.property("firebase-database.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-firestore/build.gradle.kts b/firebase-firestore/build.gradle.kts index 7ed0ae7ca..f57307d21 100644 --- a/firebase-firestore/build.gradle.kts +++ b/firebase-firestore/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -199,4 +201,39 @@ mavenPublishing { artifactId = "firebase-firestore", version = project.property("firebase-firestore.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-functions/build.gradle.kts b/firebase-functions/build.gradle.kts index 88c813863..7a9144309 100644 --- a/firebase-functions/build.gradle.kts +++ b/firebase-functions/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -178,4 +180,39 @@ mavenPublishing { artifactId = "firebase-functions", version = project.property("firebase-functions.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-installations/build.gradle.kts b/firebase-installations/build.gradle.kts index 8f94cc386..f4ccb0f18 100644 --- a/firebase-installations/build.gradle.kts +++ b/firebase-installations/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -174,4 +176,39 @@ mavenPublishing { artifactId = "firebase-installations", version = project.property("firebase-installations.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-messaging/build.gradle.kts b/firebase-messaging/build.gradle.kts index 04887e49b..54f578b86 100644 --- a/firebase-messaging/build.gradle.kts +++ b/firebase-messaging/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -172,4 +174,39 @@ mavenPublishing { artifactId = "firebase-messaging", version = project.property("firebase-messaging.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-perf/build.gradle.kts b/firebase-perf/build.gradle.kts index 188b7b5ef..05e72148c 100644 --- a/firebase-perf/build.gradle.kts +++ b/firebase-perf/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2020 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -169,4 +171,39 @@ mavenPublishing { artifactId = "firebase-perf", version = project.property("firebase-perf.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } diff --git a/firebase-storage/build.gradle.kts b/firebase-storage/build.gradle.kts index cc46955c3..4ef42e5a1 100644 --- a/firebase-storage/build.gradle.kts +++ b/firebase-storage/build.gradle.kts @@ -1,7 +1,9 @@ +import org.gradle.kotlin.dsl.distribution import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompilerOptions import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSetTree +import kotlin.text.set /* * Copyright (c) 2023 GitLive Ltd. Use of this source code is governed by the Apache 2.0 license. @@ -170,4 +172,39 @@ mavenPublishing { artifactId = "firebase-storage", version = project.property("firebase-storage.version") as String ) + + pom { + name.set("firebase-kotlin-sdk") + description.set("The Firebase Kotlin SDK is a Kotlin-first SDK for Firebase. It's API is similar to the Firebase Android SDK Kotlin Extensions but also supports multiplatform projects, enabling you to use Firebase directly from your common source targeting iOS, Android or JS.") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + inceptionYear.set("2019") + + scm { + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk") + connection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + developerConnection.set("scm:git:https://github.com/GitLiveApp/firebase-kotlin-sdk.git") + tag.set("HEAD") + } + + issueManagement { + system.set("GitHub Issues") + url.set("https://github.com/GitLiveApp/firebase-kotlin-sdk/issues") + } + + developers { + developer { + name.set("Nicholas Bransby-Williams") + email.set("nbransby@gmail.com") + } + } + + 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") + comments.set("A business-friendly OSS license") + } + } + } } From 2d2f0f6425577926b84be48bc043a2bf49b375b4 Mon Sep 17 00:00:00 2001 From: Andrew Reed Date: Thu, 14 Aug 2025 09:00:20 +0100 Subject: [PATCH 3/3] Added manual trigger for publish --- .github/workflows/publish.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 6df49ac89..e7827f376 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -6,6 +6,7 @@ name: Publish on: release: types: [ prereleased, released ] + workflow_dispatch: env: ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPEUSERNAME }}