Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
d49548b
firebase-dataconnect/demo/gradle.properties: set org.gradle.tooling.p…
dconeybe Oct 9, 2026
4e790f6
dataconnect_demo_app.yml: upgrade jdk to 21 (was 17)
dconeybe Oct 9, 2026
d4bac17
firebase-dataconnect/demo/build.gradle.kts: upgrade AGP to 8.13.2 (wa…
dconeybe Oct 9, 2026
09a6394
firebase-dataconnect/demo/build.gradle.kts: upgrade AGP to 9.4.1 (was…
dconeybe Oct 9, 2026
acbf487
firebase-dataconnect/demo/gradle/wrapper/gradle-wrapper.properties: u…
dconeybe Oct 9, 2026
e0e13ef
firebase-dataconnect/demo/gradle.properties: use # instead of // for …
dconeybe Oct 9, 2026
396676b
firebase-dataconnect/demo/build.gradle.kts: upgrade all the dependencies
dconeybe Oct 9, 2026
7ac7031
firebase-dataconnect/demo/gradle.properties: remove android.usesSdkIn…
dconeybe Oct 9, 2026
ec832da
firebase-dataconnect/demo/gradle.properties: remove android.sdk.defau…
dconeybe Oct 9, 2026
b2dc2b2
firebase-dataconnect/demo/gradle.properties: remove android.enableApp…
dconeybe Oct 9, 2026
b64f55c
firebase-dataconnect/demo/gradle.properties: remove android.r8.optimi…
dconeybe Oct 9, 2026
64bb800
firebase-dataconnect/demo/gradle.properties: remove android.defaults.…
dconeybe Oct 9, 2026
8813adc
firebase-dataconnect/demo/gradle.properties: remove android.dependenc…
dconeybe Oct 9, 2026
63a6683
firebase-dataconnect/demo/gradle.properties: remove android.builtInKo…
dconeybe Oct 9, 2026
81d4178
firebase-dataconnect/demo/gradle.properties: remove android.newDsl=false
dconeybe Oct 9, 2026
fa23c46
firebase-dataconnect/demo/build.gradle.kts: upgrade Java and JVM targ…
dconeybe Oct 9, 2026
43a929d
firebase-dataconnect/demo/build.gradle.kts: minor cleanups
dconeybe Oct 9, 2026
3e7f29e
upgrade ktfmt to 0.65 (was 0.53)
dconeybe Oct 9, 2026
229d10c
dataconnect_demo_app.yml: approve npm scripts
dconeybe Oct 9, 2026
df9c2ba
Merge branch 'main' into dconeybe/dataconnect/DemoUpgrade
dconeybe Oct 9, 2026
7d5a694
dataconnect_demo_app.yml: fix npm installs script handling
dconeybe Oct 9, 2026
203166c
dataconnect_demo_app.yml: pass firebaseCommand to dokkaGeneratePublic…
dconeybe Oct 9, 2026
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
5 changes: 4 additions & 1 deletion .github/workflows/dataconnect_demo_app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ on:
env:
FDC_NODE_VERSION: ${{ inputs.nodeVersion || '24' }}
FDC_INPUT_FIREBASE_TOOLS_VERSION: ${{ inputs.firebaseToolsVersion }}
FDC_JAVA_VERSION: ${{ inputs.javaVersion || '17' }}
FDC_JAVA_VERSION: ${{ inputs.javaVersion || '21' }}
FDC_FIREBASE_TOOLS_DIR: ${{ github.workspace }}/firebase-tools
FDC_FIREBASE_COMMAND: ${{ github.workspace }}/firebase-tools/node_modules/.bin/firebase
FDC_PYTHON_VERSION: ${{ inputs.pythonVersion || '3.13' }}
Expand Down Expand Up @@ -89,6 +89,8 @@ jobs:
cd "$FDC_FIREBASE_TOOLS_DIR"
echo '{}' > package.json
npm install --fund=false --audit=false --save --save-exact firebase-tools@"$FDC_FIREBASE_TOOLS_VERSION"
npm install-scripts approve google-logging-utils protobufjs re2
npm rebuild

- name: install firebase-tools from package-lock.json
if: steps.package_json_lock.outputs.cache-hit == 'true'
Expand Down Expand Up @@ -147,6 +149,7 @@ jobs:
--warning-mode all \
--project-dir firebase-dataconnect/demo \
${FDC_GRADLE_INFO_FLAG:+"$FDC_GRADLE_INFO_FLAG"} \
-PdataConnect.demo.firebaseCommand="$FDC_FIREBASE_COMMAND" \
dokkaGeneratePublicationHtml

- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
Expand Down
68 changes: 32 additions & 36 deletions firebase-dataconnect/demo/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -20,36 +20,35 @@ import org.jetbrains.kotlin.gradle.dsl.JvmTarget

plugins {
// Use whichever versions of these dependencies suit your application.
// The versions shown here were the latest versions as of July 17, 2025.
// The versions shown here were the latest versions as of October 09, 2026.
// Note, however, that the version of kotlin("plugin.serialization") _must_,
// in general, match the version of kotlin("android").
id("com.android.application") version "8.11.1"
id("com.google.gms.google-services") version "4.4.3"
val kotlinVersion = "2.1.10"
kotlin("android") version kotlinVersion
kotlin("plugin.serialization") version kotlinVersion
// in general, match the version of the kotlin compiler bundled with the
// Android Gradle Plugin id("com.android.application").
id("com.android.application") version "9.4.1"
kotlin("plugin.serialization") version "2.2.10"
id("com.google.gms.google-services") version "4.5.0"

// The following code in this "plugins" block can be omitted from customer
// facing documentation as it is an implementation detail of this application.
id("com.diffplug.spotless") version "7.1.0"
id("com.diffplug.spotless") version "8.10.4"

id("org.jetbrains.dokka") version "2.0.0"
id("org.jetbrains.dokka") version "2.2.0"
}

dependencies {
// Use whichever versions of these dependencies suit your application.
// The versions shown here were the latest versions as of July 17, 2025.
// The versions shown here were the latest versions as of October 09, 2026.

// Data Connect
implementation(platform("com.google.firebase:firebase-bom:33.16.0"))
implementation(platform("com.google.firebase:firebase-bom:35.0.0"))
implementation("com.google.firebase:firebase-dataconnect")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.10.2")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.10.2")
implementation("org.jetbrains.kotlinx:kotlinx-serialization-core:1.9.0")
implementation("androidx.appcompat:appcompat:1.7.1")
implementation("androidx.activity:activity-ktx:1.10.1")
implementation("androidx.lifecycle:lifecycle-viewmodel-ktx:2.9.2")
implementation("com.google.android.material:material:1.12.0")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.11.0")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.11.0")
implementation("org.jetbrains.kotlinx:kotlinx-serialization-core:1.11.0")
implementation("androidx.appcompat:appcompat:1.8.0")
implementation("androidx.activity:activity-ktx:1.13.0")
implementation("androidx.lifecycle:lifecycle-viewmodel-ktx:2.11.0")
implementation("com.google.android.material:material:1.14.0")

// The following code in this "dependencies" block can be omitted from customer
// facing documentation as it is an implementation detail of this application.
Expand All @@ -60,8 +59,8 @@ dependencies {

dokka {
moduleName.set("Data Connect Demo")
dokkaSourceSets.main {
sourceRoots.from(layout.buildDirectory.dir("dataConnect/generatedSources/").get())
dokkaSourceSets.configureEach {
sourceRoots.from(layout.buildDirectory.dir("dataConnect/generatedSources/"))
}
}

Expand All @@ -71,30 +70,30 @@ dokka {

android {
namespace = "com.google.firebase.dataconnect.minimaldemo"
compileSdk = 36
compileSdk = 37
defaultConfig {
minSdk = 24
targetSdk = 36
targetSdk = 37
versionCode = 1
versionName = "1.0"
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
isCoreLibraryDesugaringEnabled = true
}
buildFeatures.viewBinding = true
}

kotlin {
compilerOptions {
jvmTarget = JvmTarget.JVM_1_8
jvmTarget = JvmTarget.JVM_11
optIn.add("kotlin.RequiresOptIn")
}
}

spotless {
val ktfmtVersion = "0.53"
val ktfmtVersion = "0.65"
kotlin {
target("**/*.kt")
targetExclude("build/")
Expand Down Expand Up @@ -155,8 +154,6 @@ abstract class DataConnectGenerateSourcesTask : DefaultTask() {

@get:Inject protected abstract val providerFactory: ProviderFactory

@get:Inject protected abstract val fileSystemOperations: FileSystemOperations

@TaskAction
fun run() {
val inputDirectory: File = inputDirectory.get().dir
Expand Down Expand Up @@ -252,7 +249,7 @@ abstract class DataConnectGenerateSourcesTask : DefaultTask() {
}

@DisableCachingByDefault(
because = "Copying files is not worth caching, just like org.gradle.api.tasks.Copy"
because = "Copying files is not worth caching, just like org.gradle.api.tasks.Copy",
)
abstract class CopyDirectoryTask : DefaultTask() {

Expand Down Expand Up @@ -343,15 +340,14 @@ run {
description =
"Copy the generated Data Connect Kotlin SDK sources into the " +
"generated code directory for the \"${variant.name}\" variant."
srcDirectory =
generateSourcesTask.flatMap {
it.outputDirectory.map { outputDirectory ->
objectFactory.fileTree().apply {
setDir(outputDirectory)
exclude("**/*.log")
}
srcDirectory = generateSourcesTask.flatMap {
it.outputDirectory.map { outputDirectory ->
objectFactory.fileTree().apply {
setDir(outputDirectory)
exclude("**/*.log")
}
}
}
}

variant.sources.java!!.addGeneratedSourceDirectory(copyTask, CopyDirectoryTask::destDirectory)
Expand Down
55 changes: 30 additions & 25 deletions firebase-dataconnect/demo/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,36 @@ android.useAndroidX=true

org.gradle.jvmargs=-Xmx2g

// Use Dokka Gradle Plugin v2, which is technically "experimental"
// but is fine for our purposes.
// https://kotlinlang.org/docs/dokka-migration.html
# Use Dokka Gradle Plugin v2, which is technically "experimental"
# but is fine for our purposes.
# https://kotlinlang.org/docs/dokka-migration.html
org.jetbrains.dokka.experimental.gradle.pluginMode=V2Enabled
org.jetbrains.dokka.experimental.gradle.pluginMode.noWarn=true

// The path of the "firebase" command to use.
// If not specified, then "firebase" is used, resolved using the PATH environment variable.
// See build.gradle.kts for details.
//dataConnect.demo.firebaseCommand=/path/to/firebase

// The path of the directory containing the "node" and "npm" commands.
// This directory will be prepended to the PATH before running the "firebase" command
// and may be useful to override the "node" and "npm" executables that get used by it.
// See build.gradle.kts for details.
//dataConnect.demo.nodeExecutableDirectory=/path/to/node/bin

// The Data Connect emulator executable to use.
// If set, the `DATACONNECT_EMULATOR_BINARY_PATH` environment variable will be set before calling
// the "firebase" command to instruct it to use the specified Data Connect emulator rather than
// downloading an official version and using it.
// See build.gradle.kts for details.
//dataConnect.demo.dataConnectEmulatorExecutable=/path/to/cli

// A comma-separated list of "preview flags" to specify to the Data Connect emulator and codegen.
// This is used to enable features that are not (yet) intended for end-user consumption.
// See build.gradle.kts for details.
//dataConnect.demo.dataConnectPreviewFlags=flag1,flag2,flag3
# The path of the "firebase" command to use.
# If not specified, then "firebase" is used, resolved using the PATH environment variable.
# See build.gradle.kts for details.
#dataConnect.demo.firebaseCommand=/path/to/firebase

# The path of the directory containing the "node" and "npm" commands.
# This directory will be prepended to the PATH before running the "firebase" command
# and may be useful to override the "node" and "npm" executables that get used by it.
# See build.gradle.kts for details.
#dataConnect.demo.nodeExecutableDirectory=/path/to/node/bin

# The Data Connect emulator executable to use.
# If set, the `DATACONNECT_EMULATOR_BINARY_PATH` environment variable will be set before calling
# the "firebase" command to instruct it to use the specified Data Connect emulator rather than
# downloading an official version and using it.
# See build.gradle.kts for details.
#dataConnect.demo.dataConnectEmulatorExecutable=/path/to/cli

# A comma-separated list of "preview flags" to specify to the Data Connect emulator and codegen.
# This is used to enable features that are not (yet) intended for end-user consumption.
# See build.gradle.kts for details.
#dataConnect.demo.dataConnectPreviewFlags=flag1,flag2,flag3

# Enabled parallel sync for Gradle 9.4+
org.gradle.tooling.parallel=true
android.uniquePackageNames=false
android.r8.strictFullModeForKeepRules=false
Binary file modified firebase-dataconnect/demo/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.5-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-9.8.1-bin.zip
networkTimeout=10000
retries=0
retryBackOffMs=500
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
18 changes: 7 additions & 11 deletions firebase-dataconnect/demo/gradlew

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading