浏览代码

ios: don't bundle a dummy GoogleService-Info.plist file

It complicates automated builds.
j8
Saúl Ibarra Corretgé 6 年前
父节点
当前提交
f662edd135
共有 4 个文件被更改,包括 21 次插入38 次删除
  1. 1
    0
      .gitignore
  2. 0
    28
      ios/app/GoogleService-Info.plist
  3. 20
    5
      ios/app/app.xcodeproj/project.pbxproj
  4. 0
    5
      ios/app/src/FIRUtilities.m

+ 1
- 0
.gitignore 查看文件

87
 android/app/dropbox.key
87
 android/app/dropbox.key
88
 android/app/google-services.json
88
 android/app/google-services.json
89
 ios/app/dropbox.key
89
 ios/app/dropbox.key
90
+ios/app/GoogleService-Info.plist
90
 
91
 

+ 0
- 28
ios/app/GoogleService-Info.plist 查看文件

1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>API_KEY</key>
6
-	<string>correct_api_key</string>
7
-	<key>TRACKING_ID</key>
8
-	<string>correct_tracking_id</string>
9
-	<key>CLIENT_ID</key>
10
-	<string>correct_client_id</string>
11
-	<key>REVERSED_CLIENT_ID</key>
12
-	<string>com.google.correct-reversed-client-id</string>
13
-	<key>GOOGLE_APP_ID</key>
14
-	<string>1:123:ios:123abc</string>
15
-	<key>GCM_SENDER_ID</key>
16
-	<string>correct_gcm_sender_id</string>
17
-	<key>PLIST_VERSION</key>
18
-	<string>1</string>
19
-	<key>BUNDLE_ID</key>
20
-	<string>com.google.FirebaseSDKTests</string>
21
-	<key>PROJECT_ID</key>
22
-	<string>abc-xyz-123</string>
23
-	<key>DATABASE_URL</key>
24
-	<string>https://abc-xyz-123.firebaseio.com</string>
25
-	<key>STORAGE_BUCKET</key>
26
-	<string>project-id-123.storage.firebase.com</string>
27
-</dict>
28
-</plist>

+ 20
- 5
ios/app/app.xcodeproj/project.pbxproj 查看文件

18
 		13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
18
 		13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
19
 		13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
19
 		13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
20
 		695AF3ED6F686F9C5EE40F9A /* libPods-jitsi-meet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 489E8EFE2C720D10F5961AEF /* libPods-jitsi-meet.a */; };
20
 		695AF3ED6F686F9C5EE40F9A /* libPods-jitsi-meet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 489E8EFE2C720D10F5961AEF /* libPods-jitsi-meet.a */; };
21
-		DE4C455E21DE1E4300EA0709 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = DE4C455D21DE1E4300EA0709 /* GoogleService-Info.plist */; };
22
 		DE4C456121DE1E4E00EA0709 /* FIRUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = DE4C455F21DE1E4E00EA0709 /* FIRUtilities.m */; };
21
 		DE4C456121DE1E4E00EA0709 /* FIRUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = DE4C455F21DE1E4E00EA0709 /* FIRUtilities.m */; };
23
 /* End PBXBuildFile section */
22
 /* End PBXBuildFile section */
24
 
23
 
55
 		4670A512A688E2DC34528282 /* Pods-jitsi-meet.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-jitsi-meet.debug.xcconfig"; path = "../Pods/Target Support Files/Pods-jitsi-meet/Pods-jitsi-meet.debug.xcconfig"; sourceTree = "<group>"; };
54
 		4670A512A688E2DC34528282 /* Pods-jitsi-meet.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-jitsi-meet.debug.xcconfig"; path = "../Pods/Target Support Files/Pods-jitsi-meet/Pods-jitsi-meet.debug.xcconfig"; sourceTree = "<group>"; };
56
 		489E8EFE2C720D10F5961AEF /* libPods-jitsi-meet.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-jitsi-meet.a"; sourceTree = BUILT_PRODUCTS_DIR; };
55
 		489E8EFE2C720D10F5961AEF /* libPods-jitsi-meet.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-jitsi-meet.a"; sourceTree = BUILT_PRODUCTS_DIR; };
57
 		B3B083EB1D4955FF0069CEE7 /* app.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = app.entitlements; sourceTree = "<group>"; };
56
 		B3B083EB1D4955FF0069CEE7 /* app.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = app.entitlements; sourceTree = "<group>"; };
58
-		DE4C455D21DE1E4300EA0709 /* GoogleService-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = SOURCE_ROOT; };
59
 		DE4C455F21DE1E4E00EA0709 /* FIRUtilities.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FIRUtilities.m; sourceTree = "<group>"; };
57
 		DE4C455F21DE1E4E00EA0709 /* FIRUtilities.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FIRUtilities.m; sourceTree = "<group>"; };
60
 		DE4C456021DE1E4E00EA0709 /* FIRUtilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FIRUtilities.h; sourceTree = "<group>"; };
58
 		DE4C456021DE1E4E00EA0709 /* FIRUtilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FIRUtilities.h; sourceTree = "<group>"; };
61
 /* End PBXFileReference section */
59
 /* End PBXFileReference section */
91
 				13B07FB01A68108700A75B9A /* AppDelegate.m */,
89
 				13B07FB01A68108700A75B9A /* AppDelegate.m */,
92
 				DE4C456021DE1E4E00EA0709 /* FIRUtilities.h */,
90
 				DE4C456021DE1E4E00EA0709 /* FIRUtilities.h */,
93
 				DE4C455F21DE1E4E00EA0709 /* FIRUtilities.m */,
91
 				DE4C455F21DE1E4E00EA0709 /* FIRUtilities.m */,
94
-				DE4C455D21DE1E4300EA0709 /* GoogleService-Info.plist */,
95
 				13B07FB51A68108700A75B9A /* Images.xcassets */,
92
 				13B07FB51A68108700A75B9A /* Images.xcassets */,
96
 				13B07FB61A68108700A75B9A /* Info.plist */,
93
 				13B07FB61A68108700A75B9A /* Info.plist */,
97
 				13B07FB11A68108700A75B9A /* LaunchScreen.xib */,
94
 				13B07FB11A68108700A75B9A /* LaunchScreen.xib */,
149
 				0B26BE701EC5BC3C00EEFB41 /* Embed Frameworks */,
146
 				0B26BE701EC5BC3C00EEFB41 /* Embed Frameworks */,
150
 				B35383AD1DDA0083008F406A /* Adjust embedded framework architectures */,
147
 				B35383AD1DDA0083008F406A /* Adjust embedded framework architectures */,
151
 				0BB7DA181EC9E695007AAE98 /* Adjust ATS */,
148
 				0BB7DA181EC9E695007AAE98 /* Adjust ATS */,
149
+				DEF4813D224925A2002AD03A /* Copy Google Plist file */,
152
 				DEC2069321CBBD6900072F03 /* Setup Fabric */,
150
 				DEC2069321CBBD6900072F03 /* Setup Fabric */,
153
 				DE11877A21EE09640078D059 /* Setup Google reverse URL handler */,
151
 				DE11877A21EE09640078D059 /* Setup Google reverse URL handler */,
154
 				DE4F6D6E22005C0400DE699E /* Setup Dropbox */,
152
 				DE4F6D6E22005C0400DE699E /* Setup Dropbox */,
209
 			buildActionMask = 2147483647;
207
 			buildActionMask = 2147483647;
210
 			files = (
208
 			files = (
211
 				0B412F211EDEE95300B1A0A6 /* Main.storyboard in Resources */,
209
 				0B412F211EDEE95300B1A0A6 /* Main.storyboard in Resources */,
212
-				DE4C455E21DE1E4300EA0709 /* GoogleService-Info.plist in Resources */,
213
 				13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
210
 				13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
214
 				13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */,
211
 				13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */,
215
 			);
212
 			);
298
 			);
295
 			);
299
 			runOnlyForDeploymentPostprocessing = 0;
296
 			runOnlyForDeploymentPostprocessing = 0;
300
 			shellPath = /bin/sh;
297
 			shellPath = /bin/sh;
301
-			shellScript = "INFO_PLIST=\"$BUILT_PRODUCTS_DIR/$INFOPLIST_PATH\"\nREVERSED_CLIENT_ID=$(/usr/libexec/PlistBuddy -c \"Print :REVERSED_CLIENT_ID:\" $PROJECT_DIR/GoogleService-Info.plist)\n\n/usr/libexec/PlistBuddy -c \"Set :CFBundleURLTypes:1:CFBundleURLSchemes:0 $REVERSED_CLIENT_ID\" $INFO_PLIST\n";
298
+			shellScript = "INFO_PLIST=\"$BUILT_PRODUCTS_DIR/$INFOPLIST_PATH\"\nGOOGLE_PLIST=\"$PROJECT_DIR/GoogleService-Info.plist\"\n\nif [[ -f $GOOGLE_PLIST ]]; then\n    REVERSED_CLIENT_ID=$(/usr/libexec/PlistBuddy -c \"Print :REVERSED_CLIENT_ID:\" $GOOGLE_PLIST)\n    /usr/libexec/PlistBuddy -c \"Set :CFBundleURLTypes:1:CFBundleURLSchemes:0 $REVERSED_CLIENT_ID\" $INFO_PLIST\nfi\n";
302
 		};
299
 		};
303
 		DE4F6D6E22005C0400DE699E /* Setup Dropbox */ = {
300
 		DE4F6D6E22005C0400DE699E /* Setup Dropbox */ = {
304
 			isa = PBXShellScriptBuildPhase;
301
 			isa = PBXShellScriptBuildPhase;
336
 			shellPath = /bin/sh;
333
 			shellPath = /bin/sh;
337
 			shellScript = "${PODS_ROOT}/Fabric/run\n";
334
 			shellScript = "${PODS_ROOT}/Fabric/run\n";
338
 		};
335
 		};
336
+		DEF4813D224925A2002AD03A /* Copy Google Plist file */ = {
337
+			isa = PBXShellScriptBuildPhase;
338
+			buildActionMask = 2147483647;
339
+			files = (
340
+			);
341
+			inputFileListPaths = (
342
+			);
343
+			inputPaths = (
344
+			);
345
+			name = "Copy Google Plist file";
346
+			outputFileListPaths = (
347
+			);
348
+			outputPaths = (
349
+			);
350
+			runOnlyForDeploymentPostprocessing = 0;
351
+			shellPath = /bin/sh;
352
+			shellScript = "GOOGLE_PLIST_NAME=\"GoogleService-Info.plist\"\nGOOGLE_PLIST=\"$PROJECT_DIR/$GOOGLE_PLIST_NAME\"\nBUILD_APP_DIR=\"$BUILT_PRODUCTS_DIR/$PRODUCT_NAME.app\"\n\nif [[ -f $GOOGLE_PLIST ]]; then\n    cp $GOOGLE_PLIST \"$BUILD_APP_DIR/$GOOGLE_PLIST_NAME\"\nfi\n";
353
+		};
339
 /* End PBXShellScriptBuildPhase section */
354
 /* End PBXShellScriptBuildPhase section */
340
 
355
 
341
 /* Begin PBXSourcesBuildPhase section */
356
 /* Begin PBXSourcesBuildPhase section */

+ 0
- 5
ios/app/src/FIRUtilities.m 查看文件

21
 // Plist file type.
21
 // Plist file type.
22
 NSString *const kGoogleServiceInfoFileType = @"plist";
22
 NSString *const kGoogleServiceInfoFileType = @"plist";
23
 NSString *const kGoogleAppIDPlistKey = @"GOOGLE_APP_ID";
23
 NSString *const kGoogleAppIDPlistKey = @"GOOGLE_APP_ID";
24
-// Dummy plist GOOGLE_APP_ID
25
-NSString *const kDummyGoogleAppID = @"1:123:ios:123abc";
26
 
24
 
27
 
25
 
28
 @implementation FIRUtilities
26
 @implementation FIRUtilities
59
   if (!googleAppID.length) {
57
   if (!googleAppID.length) {
60
     return NO;
58
     return NO;
61
   }
59
   }
62
-  if ([googleAppID isEqualToString:kDummyGoogleAppID]) {
63
-    return NO;
64
-  }
65
 
60
 
66
   return YES;
61
   return YES;
67
 }
62
 }

正在加载...
取消
保存