Skip to content

Commit

Permalink
feat: add customerio basic setup
Browse files Browse the repository at this point in the history
  • Loading branch information
SKannaniOS committed Jun 10, 2024
1 parent 920ae0b commit 6265355
Show file tree
Hide file tree
Showing 10 changed files with 342 additions and 118 deletions.
99 changes: 98 additions & 1 deletion Example/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,100 @@ PODS:
- Sovran (= 1.1.1)
- CustomerIO/DataPipelines (3.2.2):
- CustomerIODataPipelines (= 3.2.2)
- CustomerIO/MessagingInApp (3.2.2):
- CustomerIOMessagingInApp (= 3.2.2)
- CustomerIO/MessagingPushAPN (3.2.2):
- CustomerIOMessagingPushAPN (= 3.2.2)
- CustomerIO/MessagingPushFCM (3.2.2):
- CustomerIOMessagingPushFCM (= 3.2.2)
- CustomerIOCommon (3.2.2)
- CustomerIODataPipelines (3.2.2):
- "AnalyticsSwiftCIO (= 1.5.13+cio.1)"
- CustomerIOCommon (= 3.2.2)
- CustomerIOTrackingMigration (= 3.2.2)
- CustomerIOMessagingInApp (3.2.2):
- CustomerIOCommon (= 3.2.2)
- CustomerIOMessagingPush (3.2.2):
- CustomerIOCommon (= 3.2.2)
- CustomerIOMessagingPushAPN (3.2.2):
- CustomerIOMessagingPush (= 3.2.2)
- CustomerIOMessagingPushFCM (3.2.2):
- CustomerIOMessagingPush (= 3.2.2)
- FirebaseMessaging (< 11, >= 8.7.0)
- CustomerIOTrackingMigration (3.2.2):
- CustomerIOCommon (= 3.2.2)
- FBSnapshotTestCase (2.1.4):
- FBSnapshotTestCase/SwiftSupport (= 2.1.4)
- FBSnapshotTestCase/Core (2.1.4)
- FBSnapshotTestCase/SwiftSupport (2.1.4):
- FBSnapshotTestCase/Core
- FirebaseCore (10.27.0):
- FirebaseCoreInternal (~> 10.0)
- GoogleUtilities/Environment (~> 7.12)
- GoogleUtilities/Logger (~> 7.12)
- FirebaseCoreInternal (10.27.0):
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- FirebaseInstallations (10.27.0):
- FirebaseCore (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/UserDefaults (~> 7.8)
- PromisesObjC (~> 2.1)
- FirebaseMessaging (10.27.0):
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleDataTransport (~> 9.3)
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/Reachability (~> 7.8)
- GoogleUtilities/UserDefaults (~> 7.8)
- nanopb (< 2.30911.0, >= 2.30908.0)
- GoogleDataTransport (9.4.1):
- GoogleUtilities/Environment (~> 7.7)
- nanopb (< 2.30911.0, >= 2.30908.0)
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/AppDelegateSwizzler (7.13.3):
- GoogleUtilities/Environment
- GoogleUtilities/Logger
- GoogleUtilities/Network
- GoogleUtilities/Privacy
- GoogleUtilities/Environment (7.13.3):
- GoogleUtilities/Privacy
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/Logger (7.13.3):
- GoogleUtilities/Environment
- GoogleUtilities/Privacy
- GoogleUtilities/Network (7.13.3):
- GoogleUtilities/Logger
- "GoogleUtilities/NSData+zlib"
- GoogleUtilities/Privacy
- GoogleUtilities/Reachability
- "GoogleUtilities/NSData+zlib (7.13.3)":
- GoogleUtilities/Privacy
- GoogleUtilities/Privacy (7.13.3)
- GoogleUtilities/Reachability (7.13.3):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- GoogleUtilities/UserDefaults (7.13.3):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- JSONSafeEncoding (2.0.0)
- MetricsReporter (1.2.1):
- RSCrashReporter (= 1.0.1)
- RudderKit (= 1.4.0)
- nanopb (2.30910.0):
- nanopb/decode (= 2.30910.0)
- nanopb/encode (= 2.30910.0)
- nanopb/decode (2.30910.0)
- nanopb/encode (2.30910.0)
- PromisesObjC (2.4.0)
- RSCrashReporter (1.0.1)
- Rudder (1.26.3):
- MetricsReporter (= 1.2.1)
- Rudder-CustomerIO (1.0.0):
- CustomerIO/DataPipelines (~> 3.2.2)
- CustomerIO/MessagingInApp (~> 3.2.2)
- CustomerIO/MessagingPushAPN (~> 3.2.2)
- CustomerIO/MessagingPushFCM (~> 3.2.2)
- Rudder (~> 1.26)
- RudderKit (1.4.0)
- Sovran (1.1.1)
Expand All @@ -39,10 +112,22 @@ SPEC REPOS:
- CustomerIO
- CustomerIOCommon
- CustomerIODataPipelines
- CustomerIOMessagingInApp
- CustomerIOMessagingPush
- CustomerIOMessagingPushAPN
- CustomerIOMessagingPushFCM
- CustomerIOTrackingMigration
- FBSnapshotTestCase
- FirebaseCore
- FirebaseCoreInternal
- FirebaseInstallations
- FirebaseMessaging
- GoogleDataTransport
- GoogleUtilities
- JSONSafeEncoding
- MetricsReporter
- nanopb
- PromisesObjC
- RSCrashReporter
- Rudder
- RudderKit
Expand All @@ -57,13 +142,25 @@ SPEC CHECKSUMS:
CustomerIO: e5bc96b0a188b89d53613cb0c1ca542c209f5b1c
CustomerIOCommon: 93054e3e52840c8ceec5894dd32cf548b516619d
CustomerIODataPipelines: bbf1a5bab1437efcbffe05e94537624010a3c8a4
CustomerIOMessagingInApp: aa06c5509014bc9fcddff9f9c59ddc299d603174
CustomerIOMessagingPush: 7e069140407ca55832756def8065226f6cd63ab0
CustomerIOMessagingPushAPN: e92e7ad7b2d02262cb12d9ce4420a879f9330fd5
CustomerIOMessagingPushFCM: fa0a2a82e0960e8f452367595858bfb01a6a44f0
CustomerIOTrackingMigration: 9aa4104eaede9fdecc3e43ee499950dbbb2c9687
FBSnapshotTestCase: 094f9f314decbabe373b87cc339bea235a63e07a
FirebaseCore: a2b95ae4ce7c83ceecfbbbe3b6f1cddc7415a808
FirebaseCoreInternal: 4b297a2d56063dbea2c1d0d04222d44a8d058862
FirebaseInstallations: 766dabca09fd94aef922538aaf144cc4a6fb6869
FirebaseMessaging: 585984d0a1df120617eb10b44cad8968b859815e
GoogleDataTransport: 6c09b596d841063d76d4288cc2d2f42cc36e1e2a
GoogleUtilities: ea963c370a38a8069cc5f7ba4ca849a60b6d7d15
JSONSafeEncoding: 54722ebc4fe1482e3e60a8450e1287481e32dd8b
MetricsReporter: 99596ee5003c69949ed2f50acc34aee83c42f843
nanopb: 438bc412db1928dac798aa6fd75726007be04262
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
RSCrashReporter: 6b8376ac729b0289ebe0908553e5f56d8171f313
Rudder: 23456f79749849870e18c45bd250d6e2229a7147
Rudder-CustomerIO: 3f92165eb87c4db57c205680371fd53688a10b7c
Rudder-CustomerIO: 6fc49da9c3b9bbc6fee08b989e78eb9317b790d9
RudderKit: f272f9872183946452ac94cd7bb2244a71e6ca8f
Sovran: f8212bb3855042a24689a73ea0219ca5295235da

Expand Down
24 changes: 24 additions & 0 deletions Example/Rudder-CustomerIO.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -335,26 +335,50 @@
"${BUILT_PRODUCTS_DIR}/AnalyticsSwiftCIO/CioAnalytics.framework",
"${BUILT_PRODUCTS_DIR}/CustomerIOCommon/CioInternalCommon.framework",
"${BUILT_PRODUCTS_DIR}/CustomerIODataPipelines/CioDataPipelines.framework",
"${BUILT_PRODUCTS_DIR}/CustomerIOMessagingInApp/CioMessagingInApp.framework",
"${BUILT_PRODUCTS_DIR}/CustomerIOMessagingPush/CioMessagingPush.framework",
"${BUILT_PRODUCTS_DIR}/CustomerIOMessagingPushAPN/CioMessagingPushAPN.framework",
"${BUILT_PRODUCTS_DIR}/CustomerIOMessagingPushFCM/CioMessagingPushFCM.framework",
"${BUILT_PRODUCTS_DIR}/CustomerIOTrackingMigration/CioTrackingMigration.framework",
"${BUILT_PRODUCTS_DIR}/FirebaseCore/FirebaseCore.framework",
"${BUILT_PRODUCTS_DIR}/FirebaseCoreInternal/FirebaseCoreInternal.framework",
"${BUILT_PRODUCTS_DIR}/FirebaseInstallations/FirebaseInstallations.framework",
"${BUILT_PRODUCTS_DIR}/FirebaseMessaging/FirebaseMessaging.framework",
"${BUILT_PRODUCTS_DIR}/GoogleDataTransport/GoogleDataTransport.framework",
"${BUILT_PRODUCTS_DIR}/GoogleUtilities/GoogleUtilities.framework",
"${BUILT_PRODUCTS_DIR}/JSONSafeEncoding/JSONSafeEncoding.framework",
"${BUILT_PRODUCTS_DIR}/MetricsReporter/MetricsReporter.framework",
"${BUILT_PRODUCTS_DIR}/PromisesObjC/FBLPromises.framework",
"${BUILT_PRODUCTS_DIR}/RSCrashReporter/RSCrashReporter.framework",
"${BUILT_PRODUCTS_DIR}/Rudder/Rudder.framework",
"${BUILT_PRODUCTS_DIR}/RudderKit/RudderKit.framework",
"${BUILT_PRODUCTS_DIR}/Sovran/Sovran.framework",
"${BUILT_PRODUCTS_DIR}/nanopb/nanopb.framework",
);
name = "[CP] Embed Pods Frameworks";
outputPaths = (
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioAnalytics.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioInternalCommon.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioDataPipelines.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioMessagingInApp.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioMessagingPush.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioMessagingPushAPN.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioMessagingPushFCM.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/CioTrackingMigration.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/FirebaseCore.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/FirebaseCoreInternal.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/FirebaseInstallations.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/FirebaseMessaging.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/GoogleDataTransport.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/GoogleUtilities.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/JSONSafeEncoding.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MetricsReporter.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/FBLPromises.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/RSCrashReporter.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Rudder.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/RudderKit.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Sovran.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/nanopb.framework",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
Expand Down
3 changes: 1 addition & 2 deletions Example/Rudder-CustomerIO/_AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@

#import "_AppDelegate.h"
#import <Rudder/Rudder.h>
#import "RudderCustomerIOFactory.h"
#import "Rudder_CustomerIO_Example-Swift.h"

#import "Rudder_CustomerIO-Swift.h"
@implementation _AppDelegate

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
Expand Down
22 changes: 14 additions & 8 deletions Rudder-CustomerIO.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@ package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
rudder_sdk_version = '~> 1.26'
deployment_target = '13.0'

customerio_sdk_name = 'CustomerIO/DataPipelines'
customerio_sdk_name1 = 'CustomerIO/DataPipelines'
customerio_sdk_name2 = 'CustomerIO/MessagingPushAPN'
customerio_sdk_name3 = 'CustomerIO/MessagingPushFCM'
customerio_sdk_name4 = 'CustomerIO/MessagingInApp'
customerio_sdk_version = '~> 3.2.2'

Pod::Spec.new do |s|
Expand All @@ -26,12 +29,12 @@ Pod::Spec.new do |s|
s.static_framework = true
s.ios.deployment_target = deployment_target

if defined?($CustomerIOSDKVersion)
Pod::UI.puts "#{s.name}: Using user specified Braze SDK version '#{$CustomerIOSDKVersion}'"
customerio_sdk_version = $CustomerIOSDKVersion
else
Pod::UI.puts "#{s.name}: Using default Braze SDK version '#{CustomerIOSDKVersion}'"
end
# if defined?($CustomerIOSDKVersion)
# Pod::UI.puts "#{s.name}: Using user specified Braze SDK version '#{$CustomerIOSDKVersion}'"
# customerio_sdk_version = $CustomerIOSDKVersion
# else
# Pod::UI.puts "#{s.name}: Using default Braze SDK version '#{CustomerIOSDKVersion}'"
# end

if defined?($RudderSDKVersion)
Pod::UI.puts "#{s.name}: Using user specified Rudder SDK version '#{$RudderSDKVersion}'"
Expand All @@ -41,6 +44,9 @@ Pod::Spec.new do |s|
end

s.dependency 'Rudder', rudder_sdk_version
s.dependency customerio_sdk_name, customerio_sdk_version
s.dependency customerio_sdk_name1, customerio_sdk_version
# s.dependency customerio_sdk_name2, customerio_sdk_version
# s.dependency customerio_sdk_name3, customerio_sdk_version
# s.dependency customerio_sdk_name4, customerio_sdk_version

end
18 changes: 0 additions & 18 deletions Rudder-CustomerIO/Classes/RudderCustomerIOFactory.h

This file was deleted.

31 changes: 0 additions & 31 deletions Rudder-CustomerIO/Classes/RudderCustomerIOFactory.m

This file was deleted.

29 changes: 29 additions & 0 deletions Rudder-CustomerIO/Classes/RudderCustomerIOFactory.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
//
// RudderCustomerIOFactory.swift
// Rudder-CustomerIO
//
// Created by Satheesh Kannan on 07/06/24.
//

import Foundation
import Rudder

// MARK: - RudderCustomerIOFactory
@objcMembers
public class RudderCustomerIOFactory: NSObject, RSIntegrationFactory {

// MARK: - Instance
public static let instance: RudderCustomerIOFactory = RudderCustomerIOFactory()

// MARK: - Initializer
public func initiate(_ config: [AnyHashable : Any], client: RSClient, rudderConfig: RSConfig) -> any RSIntegration {
RSLogger.logDebug("Creating RudderIntegrationFactory")

return RudderCustomerIOIntegration(config: config, client: client, rudderConfig: rudderConfig)
}

// MARK: - Key
public func key() -> String {
return "Customer IO"
}
}
18 changes: 0 additions & 18 deletions Rudder-CustomerIO/Classes/RudderCustomerIOIntegration.h

This file was deleted.

40 changes: 0 additions & 40 deletions Rudder-CustomerIO/Classes/RudderCustomerIOIntegration.m

This file was deleted.

Loading

0 comments on commit 6265355

Please sign in to comment.