Skip to content

Commit f852df8

Browse files
authored
feat(functions): add support for Pigeon. Update android to Kotlin. (#17433)
* feat(functions): add support for Pigeon * chore: fix ci * chore: fix ci
1 parent d2b660c commit f852df8

File tree

24 files changed

+1223
-538
lines changed

24 files changed

+1223
-538
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Copyright 2025 The Chromium Authors. All rights reserved.
2+
# Use of this source code is governed by a BSD-style license that can be
3+
# in the LICENSE file.
4+
5+
include: ../../analysis_options.yaml
6+
7+
analyzer:
8+
exclude:
9+
- cloud_functions_platform_interface/lib/src/pigeon/messages.pigeon.dart
10+
- cloud_functions_platform_interface/test/pigeon/test_api.dart

packages/cloud_functions/cloud_functions/android/build.gradle

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,19 @@ version '1.0-SNAPSHOT'
33

44
apply plugin: 'com.android.library'
55
apply from: file("local-config.gradle")
6+
apply plugin: 'kotlin-android'
67

78
buildscript {
9+
ext.kotlin_version = "1.8.22"
810
repositories {
911
google()
1012
mavenCentral()
1113
}
14+
15+
dependencies {
16+
classpath 'com.android.tools.build:gradle:8.1.4'
17+
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version")
18+
}
1219
}
1320

1421
rootProject.allprojects {
@@ -48,7 +55,12 @@ android {
4855
sourceCompatibility project.ext.javaVersion
4956
targetCompatibility project.ext.javaVersion
5057
}
51-
58+
59+
sourceSets {
60+
main.java.srcDirs += "src/main/kotlin"
61+
test.java.srcDirs += "src/test/kotlin"
62+
}
63+
5264
buildFeatures {
5365
buildConfig = true
5466
}
@@ -64,6 +76,12 @@ android {
6476
implementation 'androidx.annotation:annotation:1.7.0'
6577
implementation 'org.reactivestreams:reactive-streams:1.0.4'
6678
}
79+
80+
kotlinOptions {
81+
jvmTarget = JavaVersion.VERSION_17
82+
}
83+
6784
}
6885

6986
apply from: file("./user-agent.gradle")
87+
apply plugin: 'org.jetbrains.kotlin.android'

packages/cloud_functions/cloud_functions/android/src/main/java/io/flutter/plugins/firebase/functions/FirebaseFunctionsStreamHandler.java

Lines changed: 0 additions & 85 deletions
This file was deleted.

packages/cloud_functions/cloud_functions/android/src/main/java/io/flutter/plugins/firebase/functions/FlutterFirebaseAppRegistrar.java

Lines changed: 0 additions & 21 deletions
This file was deleted.

packages/cloud_functions/cloud_functions/android/src/main/java/io/flutter/plugins/firebase/functions/FlutterFirebaseFunctionsPlugin.java

Lines changed: 0 additions & 216 deletions
This file was deleted.

0 commit comments

Comments
 (0)