Skip to content

Commit f35939a

Browse files
authored
[Infra] Convert FirebaseAnalyticsOnDeviceConversion JSON podspec to Ruby (#9785)
* Rename FirebaseAnalyticsOnDeviceConversion.podspec.json to FirebaseAnalyticsOnDeviceConversion.podspec * Convert JSON podspec to ruby * Directly translate dep versioning * Remove trailing whitespace * Update FirebaseManifest.swift * Update .github/workflows/analytics.yml * Updat Dangerfile * This maybe works? * It pretty much worked * Revert FirebaseAnalyticsSwift/Sources/Analytics+SwiftUI.swift * Fix CI
1 parent 05f9b2d commit f35939a

File tree

5 files changed

+49
-29
lines changed

5 files changed

+49
-29
lines changed

.github/workflows/analytics.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@ name: analytics
33
on:
44
pull_request:
55
paths:
6-
- 'FirebaseAnalytics.podspec.json'
7-
- 'FirebaseAnalyticsSwift**'
8-
- 'GoogleAppMeasurement.podspec.json'
6+
- 'FirebaseAnalytics**'
7+
- 'GoogleAppMeasurement**'
98
- '.github/workflows/analytics.yml'
109
- 'Gemfile*'
1110
schedule:
@@ -37,6 +36,11 @@ jobs:
3736
run: scripts/third_party/travis/retry.sh pod spec lint GoogleAppMeasurement.podspec.json --platforms=${{ matrix.target }} --sources=https://github.com/firebase/SpecsDev.git,https://github.com/firebase/SpecsStaging.git,https://cdn.cocoapods.org/
3837
- name: FirebaseAnalyticsSwift
3938
run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseAnalyticsSwift.podspec --platforms=${{ matrix.target }}
39+
# The following steps are only run on `ios` due to product availability.
40+
- name: GoogleAppMeasurementOnDeviceConversion
41+
run: scripts/third_party/travis/retry.sh pod spec lint GoogleAppMeasurementOnDeviceConversion.podspec.json --platforms=ios --sources=https://github.com/firebase/SpecsDev.git,https://github.com/firebase/SpecsStaging.git,https://cdn.cocoapods.org/
42+
- name: FirebaseAnalyticsOnDeviceConversion
43+
run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseAnalyticsOnDeviceConversion.podspec --platforms=ios
4044

4145
# TODO: Consider pushing GoogleAppMeasurement.podspec.json to SpecsDev to enable similar test
4246
# for FirebaseAnalytics.podspec.json

Dangerfile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ end
3535
# multiple directories may have multiple labels.
3636
def labelsForModifiedFiles()
3737
labels = []
38+
labels.push("api: analytics") if @has_analytics_changes
3839
labels.push("api: abtesting") if @has_abtesting_changes
3940
labels.push("api: appcheck") if @has_appcheck_changes
4041
labels.push("api: appdistribution") if @has_appdistribution_changes
@@ -70,6 +71,18 @@ has_changelog_changes = hasChangesIn(["CHANGELOG"])
7071
has_license_changes = didModify(["LICENSE"])
7172

7273
## Product directories
74+
@has_analytics_changes = hasChangesIn([
75+
"FirebaseAnalyticsOnDeviceConversionWrapper",
76+
"FirebaseAnalyticsSwift",
77+
"FirebaseAnalyticsWithoutAdIdSupportWrapper",
78+
"FirebaseAnalyticsWrapper"
79+
]) || didModify([
80+
"FirebaseAnalytics.podspec.json",
81+
"FirebaseAnalyticsSwift.podspec",
82+
"FirebaseAnalyticsOnDeviceConversion.podspec",
83+
"GoogleAppMeasurement.podspec.json",
84+
"GoogleAppMeasurementOnDeviceConversion.podspec.json"
85+
])
7386
@has_abtesting_changes = hasChangesIn("FirebaseABTesting")
7487
@has_abtesting_api_changes = hasChangesIn("FirebaseABTesting/Sources/Public/")
7588
@has_appcheck_changes = hasChangesIn("FirebaseAppCheck")
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
Pod::Spec.new do |s|
2+
s.name = 'FirebaseAnalyticsOnDeviceConversion'
3+
s.version = '9.0.0'
4+
s.summary = 'On device conversion measurement plugin for FirebaseAnalytics. Not intended for direct use.'
5+
6+
s.description = <<-DESC
7+
On device conversion measurement plugin for FirebaseAnalytics. This pod does not expose any headers and isn't intended for direct use, but rather as a plugin of FirebaseAnalytics.
8+
DESC
9+
10+
s.homepage = 'https://firebase.google.com/features/analytics/'
11+
s.license = { :type => 'Copyright', :text => 'Copyright 2022 Google' }
12+
s.authors = 'Google, Inc.'
13+
14+
s.source = {
15+
:git => 'https://github.com/firebase/firebase-ios-sdk.git',
16+
:tag => 'CocoaPods-' + s.version.to_s
17+
}
18+
19+
s.cocoapods_version = '>= 1.10.2'
20+
21+
s.dependency 'GoogleAppMeasurementOnDeviceConversion', '9.0'
22+
23+
s.static_framework = true
24+
25+
s.ios.deployment_target = '10.0'
26+
27+
s.source_files = 'FirebaseAnalyticsOnDeviceConversionWrapper/*'
28+
end

FirebaseAnalyticsOnDeviceConversion.podspec.json

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

ReleaseTooling/Sources/FirebaseManifest/FirebaseManifest.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public let shared = Manifest(
3535
Pod("GoogleAppMeasurement", isClosedSource: true),
3636
Pod("GoogleAppMeasurementOnDeviceConversion", isClosedSource: true, platforms: ["ios"]),
3737
Pod("FirebaseAnalytics", isClosedSource: true),
38-
Pod("FirebaseAnalyticsOnDeviceConversion", isClosedSource: true, platforms: ["ios"], zip: true),
38+
Pod("FirebaseAnalyticsOnDeviceConversion", platforms: ["ios"], zip: true),
3939
Pod("FirebaseAnalyticsSwift", zip: true),
4040
Pod("FirebaseABTesting", zip: true),
4141
Pod("FirebaseAppCheck", zip: true),

0 commit comments

Comments
 (0)