Skip to content

Commit 0b0e2cb

Browse files
authored
feat: GA 23 Kit Migrate (#652)
* feat: migrate googleanalyticsfirebase-kit from submodule to regular directory * feat: relocate googleanalyticsfirebase-kit to kits/ga/ga-23 and update settings-kits.gradle Made-with: Cursor * fix agent typo * add bracket
1 parent 52cf963 commit 0b0e2cb

19 files changed

Lines changed: 2217 additions & 6 deletions

.gitmodules

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,6 @@
3737
[submodule "kits/foresee-kit"]
3838
path = kits/foresee-kit
3939
url = git@github.com:mparticle-integrations/mparticle-android-integration-foresee.git
40-
[submodule "kits/googleanalyticsfirebase-kit"]
41-
path = kits/googleanalyticsfirebase-kit
42-
url = git@github.com:mparticle-integrations/mparticle-android-integration-google-analytics-firebase.git
4340
[submodule "kits/googleanalyticsfirebasega4-kit"]
4441
path = kits/googleanalyticsfirebasega4-kit
4542
url = git@github.com:mparticle-integrations/mparticle-android-integration-google-analytics-firebase-ga4.git

.trunk/trunk.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ lint:
6969
- scripts/install-start-emulator.sh
7070
- kits/appsflyer/appsflyer-6/**
7171
- kits/braze/braze-38/**
72+
- kits/ga/ga-23/**
7273
actions:
7374
enabled:
7475
- trunk-announce

kits/ga/ga-23/README.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
> Google launched Google Analytics 4, a new way of analyzing iOS, Android, and Web data together. Google encourages all customers to [upgrade their Firebase instances](https://support.google.com/analytics/answer/9379599) so that Firebase data flows to Google Analytics 4. mParticle encourages all customers to also upgrade to the [new mParticle Android Firebase GA4 kit](https://github.com/mparticle-integrations/mparticle-android-integration-google-analytics-firebase-ga4). Please see the [mParticle GA4](https://docs.mparticle.com/integrations/google-analytics-4/event) docs for more information on upgrading.
2+
3+
## Google Analytics for Firebase Kit Integration
4+
5+
This repository contains the [Google Analytics for Firebase](https://firebase.google.com/docs/analytics/android/start) integration for the [mParticle Android SDK](https://github.com/mParticle/mparticle-android-sdk).
6+
7+
### Adding the integration
8+
9+
1. Add the kit dependency to your app's build.gradle:
10+
11+
```groovy
12+
dependencies {
13+
implementation 'com.mparticle:android-googleanalyticsfirebase-kit:5+'
14+
}
15+
```
16+
2. Follow the mParticle Android SDK [quick-start](https://github.com/mParticle/mparticle-android-sdk), then rebuild and launch your app, and verify that you see `"Google Analytics for Firebase detected"` in the output of `adb logcat`.
17+
3. Reference mParticle's integration docs below to enable the integration.
18+
19+
### Documentation
20+
21+
[Google Analytics for Firebase integration](http://docs.mparticle.com/integrations/firebase)
22+
23+
### License
24+
25+
[Apache License 2.0](http://www.apache.org/licenses/LICENSE-2.0)

kits/ga/ga-23/build.gradle

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
buildscript {
2+
ext.kotlin_version = '2.0.20'
3+
if (!project.hasProperty('version') || project.version.equals('unspecified')) {
4+
project.version = '+'
5+
}
6+
7+
repositories {
8+
google()
9+
mavenLocal()
10+
mavenCentral()
11+
}
12+
13+
dependencies {
14+
classpath 'com.android.tools.build:gradle:8.1.4'
15+
classpath 'com.mparticle:android-kit-plugin:' + project.version
16+
classpath 'com.google.gms:google-services:4.3.15'
17+
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
18+
}
19+
}
20+
21+
plugins {
22+
id "org.sonarqube" version "3.5.0.2730"
23+
id "org.jlleitschuh.gradle.ktlint" version "13.0.0"
24+
}
25+
26+
sonarqube {
27+
properties {
28+
property "sonar.projectKey", "mparticle-android-integration-google-analytics-firebase"
29+
property "sonar.organization", "mparticle"
30+
property "sonar.host.url", "https://sonarcloud.io"
31+
}
32+
}
33+
34+
apply plugin: 'org.jlleitschuh.gradle.ktlint'
35+
apply plugin: 'kotlin-android'
36+
apply plugin: 'com.mparticle.kit'
37+
38+
android {
39+
namespace 'com.mparticle.kits.googleanalyticsfirebase'
40+
buildFeatures {
41+
buildConfig = true
42+
}
43+
defaultConfig {
44+
minSdkVersion 21
45+
}
46+
compileOptions {
47+
sourceCompatibility JavaVersion.VERSION_17
48+
targetCompatibility JavaVersion.VERSION_17
49+
}
50+
kotlinOptions {
51+
jvmTarget = '17'
52+
}
53+
testOptions {
54+
unitTests.all {
55+
jvmArgs += ['--add-opens', 'java.base/java.lang=ALL-UNNAMED']
56+
}
57+
}
58+
}
59+
60+
dependencies {
61+
testImplementation files('libs/java-json.jar')
62+
testImplementation files('libs/test-utils.aar')
63+
testImplementation 'com.google.android.gms:play-services-measurement-api:22.1.0'
64+
compileOnly 'com.google.firebase:firebase-analytics:22.1.0'
65+
}

kits/ga/ga-23/gradle.properties

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
android.enableJetifier=true
2+
android.useAndroidX=true
3+
org.gradle.daemon=true
4+
org.gradle.jvmargs=-Xmx2560m
58.4 KB
Binary file not shown.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
distributionBase=GRADLE_USER_HOME
2+
distributionPath=wrapper/dists
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.2-bin.zip
4+
zipStoreBase=GRADLE_USER_HOME
5+
zipStorePath=wrapper/dists

kits/ga/ga-23/gradlew

Lines changed: 234 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)