File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,12 @@ target 'InstabugSample' do
28
28
pod 'glog' , :podspec => '../node_modules/react-native/third-party-podspecs/glog.podspec'
29
29
pod 'Folly' , :podspec => '../node_modules/react-native/third-party-podspecs/Folly.podspec'
30
30
31
+ post_install do |installer |
32
+ ## Fix for XCode 12.5 beta
33
+ find_and_replace ( "../node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm" ,
34
+ "_initializeModules:(NSArray<id<RCTBridgeModule>> *)modules" , "_initializeModules:(NSArray<Class> *)modules" )
35
+ end
36
+
31
37
target 'InstabugSampleTests' do
32
38
inherit! :search_paths
33
39
# Pods for testing
@@ -36,3 +42,17 @@ target 'InstabugSample' do
36
42
37
43
use_native_modules!
38
44
end
45
+
46
+ def find_and_replace ( dir , findstr , replacestr )
47
+ Dir [ dir ] . each do |name |
48
+ text = File . read ( name )
49
+ replace = text . gsub ( findstr , replacestr )
50
+ if text != replace
51
+ puts "Fix: " + name
52
+ File . open ( name , "w" ) { |file | file . puts replace }
53
+ STDOUT . flush
54
+ end
55
+ end
56
+ Dir [ dir + '*/' ] . each ( &method ( :find_and_replace ) )
57
+ end
58
+
You can’t perform that action at this time.
0 commit comments