diff --git a/.github/workflows/ios_deploy.yml b/.github/workflows/ios_deploy.yml
index 7e9aa953..6e5faa5f 100644
--- a/.github/workflows/ios_deploy.yml
+++ b/.github/workflows/ios_deploy.yml
@@ -40,6 +40,10 @@ jobs:
cd khelo
echo $FIREBASE_OPTIONS_BASE64 | base64 --decode > lib/firebase_options.dart
echo $GOOGLE_SERVICE_INFO_PLIST_BASE64 | base64 --decode > ios/Runner/GoogleService-Info.plist
+ echo "Decoded Firebase options:"
+ cat lib/firebase_options.dart
+ echo "Decoded GoogleService-Info.plist:"
+ cat ios/Runner/GoogleService-Info.plist
- name: Install Dependencies
run: |
@@ -62,6 +66,8 @@ jobs:
PROFILE_PATH="$(mktemp "$PROFILES_HOME"/$(uuidgen).mobileprovision)"
echo ${DIST_PROFILE} | base64 --decode > "$PROFILE_PATH"
echo "Saved Provisioning profile $PROFILE_PATH"
+ echo "Provisioning Profile Content:"
+ cat "$PROFILE_PATH"
- name: Set up Signing certificate
run: |
@@ -71,6 +77,11 @@ jobs:
- name: Set up code signing settings on Xcode project
run: xcode-project use-profiles
+ - name: print plist option
+ run: |
+ echo "Printing export options plist content:"
+ cat $HOME/export_options.plist
+
- name: Build ipa for distribution
run: |
cd khelo
diff --git a/khelo/ios/Runner.xcodeproj/project.pbxproj b/khelo/ios/Runner.xcodeproj/project.pbxproj
index 644c1fe0..02cbcd14 100644
--- a/khelo/ios/Runner.xcodeproj/project.pbxproj
+++ b/khelo/ios/Runner.xcodeproj/project.pbxproj
@@ -718,7 +718,7 @@
PRODUCT_BUNDLE_IDENTIFIER = com.canopas.khelo;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
- "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "provision-khelo-distribution-2024-05-16";
+ "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "provision-khelo-distribution-2024-06-12";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
SWIFT_VERSION = 5.0;
VERSIONING_SYSTEM = "apple-generic";
diff --git a/khelo/ios/Runner/AppDelegate.swift b/khelo/ios/Runner/AppDelegate.swift
index 70693e4a..e087d038 100644
--- a/khelo/ios/Runner/AppDelegate.swift
+++ b/khelo/ios/Runner/AppDelegate.swift
@@ -1,5 +1,7 @@
import UIKit
import Flutter
+import Firebase
+import FirebaseAuth
@UIApplicationMain
@objc class AppDelegate: FlutterAppDelegate {
@@ -7,7 +9,21 @@ import Flutter
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
+ FirebaseApp.configure()
GeneratedPluginRegistrant.register(with: self)
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
}
+
+ override func application(_ application: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data) {
+ let firebaseAuth = Auth.auth()
+ firebaseAuth.setAPNSToken(deviceToken, type: AuthAPNSTokenType.unknown)
+ }
+
+ override func application(_ application: UIApplication, didReceiveRemoteNotification userInfo: [AnyHashable : Any], fetchCompletionHandler completionHandler: @escaping (UIBackgroundFetchResult) -> Void) {
+ let firebaseAuth = Auth.auth()
+ if (firebaseAuth.canHandleNotification(userInfo)){
+ print(userInfo)
+ return
+ }
+ }
}
diff --git a/khelo/ios/Runner/Info.plist b/khelo/ios/Runner/Info.plist
index ee12496c..bfec7abe 100644
--- a/khelo/ios/Runner/Info.plist
+++ b/khelo/ios/Runner/Info.plist
@@ -30,6 +30,7 @@
CFBundleURLSchemes
app-1-753506519474-ios-8cd38557e090c0b51e7cab
+ com.googleusercontent.apps.753506519474-6qolf71653023s197ur4ag97q2lvaf9r
@@ -40,11 +41,16 @@
LSRequiresIPhoneOS
NSCameraUsageDescription
- Capture a new profile image using your device's camera for a personalized and up-to-date appearance.
+ Capture a new profile image using your device's camera for a personalized and up-to-date appearance.
NSPhotoLibraryUsageDescription
- Select a profile image from your device's gallery to showcase your preferred photo in moments of your choice.
+ Select a profile image from your device's gallery to showcase your preferred photo in moments of your choice.
UIApplicationSupportsIndirectInputEvents
+ UIBackgroundModes
+
+ fetch
+ remote-notification
+
UILaunchStoryboardName
LaunchScreen
UIMainStoryboardFile
diff --git a/khelo/ios/Runner/RunnerRelease.entitlements b/khelo/ios/Runner/RunnerRelease.entitlements
index 903def2a..98ff2408 100644
--- a/khelo/ios/Runner/RunnerRelease.entitlements
+++ b/khelo/ios/Runner/RunnerRelease.entitlements
@@ -3,6 +3,6 @@
aps-environment
- development
+ unknown
diff --git a/khelo/lib/ui/flow/my_game/my_game_tab_screen.dart b/khelo/lib/ui/flow/my_game/my_game_tab_screen.dart
index b9a4af31..73d9de48 100644
--- a/khelo/lib/ui/flow/my_game/my_game_tab_screen.dart
+++ b/khelo/lib/ui/flow/my_game/my_game_tab_screen.dart
@@ -1,4 +1,3 @@
-import 'package:firebase_crashlytics/firebase_crashlytics.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
@@ -147,8 +146,7 @@ class _MyGameTabScreenState extends ConsumerState
return LargeIconButton(
backgroundColor: context.colorScheme.primary,
onTap: () async {
- // AppRoute.addMatch().push(context);
- FirebaseCrashlytics.instance.crash();
+ AppRoute.addMatch().push(context);
},
icon: Icon(
Icons.add_rounded,
diff --git a/khelo/macos/firebase_app_id_file.json b/khelo/macos/firebase_app_id_file.json
deleted file mode 100644
index 9162fef5..00000000
--- a/khelo/macos/firebase_app_id_file.json
+++ /dev/null
@@ -1,7 +0,0 @@
-{
- "file_generated_by": "FlutterFire CLI",
- "purpose": "FirebaseAppID & ProjectID for this Firebase app in this directory",
- "GOOGLE_APP_ID": "1:92999931839:ios:984233dbd06405beac330a",
- "FIREBASE_PROJECT_ID": "khelo-dev-8040e",
- "GCM_SENDER_ID": "92999931839"
-}
\ No newline at end of file