Skip to content

Commit f1e8d39

Browse files
updated podfile
1 parent c5b379b commit f1e8d39

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

InstabugSample/ios/Podfile

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,20 @@ target 'InstabugSample' do
2727
post_install do |installer|
2828
react_native_post_install(installer)
2929
__apply_Xcode_12_5_M1_post_install_workaround(installer)
30+
## Fix for XCode 12.5 beta
31+
find_and_replace("../node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm",
32+
"_initializeModules:(NSArray<id<RCTBridgeModule>> *)modules", "_initializeModules:(NSArray<Class> *)modules")
3033
end
3134
end
35+
def find_and_replace(dir, findstr, replacestr)
36+
Dir[dir].each do |name|
37+
text = File.read(name)
38+
replace = text.gsub(findstr,replacestr)
39+
if text != replace
40+
puts "Fix: " + name
41+
File.open(name, "w") { |file| file.puts replace }
42+
STDOUT.flush
43+
end
44+
end
45+
Dir[dir + '*/'].each(&method(:find_and_replace))
46+
end

0 commit comments

Comments
 (0)