From 3c03c0a5b780e1378742d1281e4f74224d7b65fc Mon Sep 17 00:00:00 2001 From: Chris Bobbe Date: Tue, 19 Jan 2021 15:38:57 -0500 Subject: [PATCH] podfile [nfc]: Set up Flipper Pods by calling a function exposed by RN. Instead of spelling out the exact same code ourselves. Corresponds to the portion of facebook/react-native@619d5d60d that was missing in its backport to RN v0.62 (facebook/react-native@b4d1fcfb2); we took all of that incomplete backport in 9a144c5b3. After aligning our Podfile code with the corresponding code in the RN v0.63 script, in #4322, this change can be done as an NFC commit after the RN v0.63 upgrade commit. --- ios/Podfile | 46 +--------------------------------------------- ios/Podfile.lock | 2 +- 2 files changed, 2 insertions(+), 46 deletions(-) diff --git a/ios/Podfile b/ios/Podfile index cdb7d9b677c..2a81fe4902e 100644 --- a/ios/Podfile +++ b/ios/Podfile @@ -6,50 +6,6 @@ require_relative '../node_modules/react-native/scripts/react_native_pods' require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules' require_relative '../node_modules/react-native-unimodules/cocoapods.rb' -# Add Flipper Pods -def add_flipper_pods!(versions = {}, configurations: ['Debug']) - versions['Flipper'] ||= '~> 0.54.0' - versions['Flipper-DoubleConversion'] ||= '1.1.7' - versions['Flipper-Folly'] ||= '~> 2.2' - versions['Flipper-Glog'] ||= '0.3.6' - versions['Flipper-PeerTalk'] ||= '~> 0.0.4' - versions['Flipper-RSocket'] ||= '~> 1.1' - - pod 'FlipperKit', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FlipperKitLayoutPlugin', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/SKIOSNetworkPlugin', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FlipperKitUserDefaultsPlugin', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FlipperKitReactPlugin', versions['Flipper'], :configurations => configurations - - # List all transitive dependencies for FlipperKit pods - # to avoid them being linked in Release builds - pod 'Flipper', versions['Flipper'], :configurations => configurations - pod 'Flipper-DoubleConversion', versions['Flipper-DoubleConversion'], :configurations => configurations - pod 'Flipper-Folly', versions['Flipper-Folly'], :configurations => configurations - pod 'Flipper-Glog', versions['Flipper-Glog'], :configurations => configurations - pod 'Flipper-PeerTalk', versions['Flipper-PeerTalk'], :configurations => configurations - pod 'Flipper-RSocket', versions['Flipper-RSocket'], :configurations => configurations - pod 'FlipperKit/Core', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/CppBridge', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FBCxxFollyDynamicConvert', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FBDefines', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FKPortForwarding', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FlipperKitHighlightOverlay', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FlipperKitLayoutTextSearchable', versions['Flipper'], :configurations => configurations - pod 'FlipperKit/FlipperKitNetworkPlugin', versions['Flipper'], :configurations => configurations -end - -# Post Install processing for Flipper -def flipper_post_install(installer) - installer.pods_project.targets.each do |target| - if target.name == 'YogaKit' - target.build_configurations.each do |config| - config.build_settings['SWIFT_VERSION'] = '4.1' - end - end - end -end - target 'ZulipMobile' do # Pods from React Native use_react_native! @@ -66,7 +22,7 @@ target 'ZulipMobile' do # # Note that if you have use_frameworks! enabled, Flipper will not work and # you should disable these next few lines. - add_flipper_pods! + use_flipper! post_install do |installer| flipper_post_install(installer) end diff --git a/ios/Podfile.lock b/ios/Podfile.lock index 46737398287..399355532a0 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -721,6 +721,6 @@ SPEC CHECKSUMS: Yoga: 4bd86afe9883422a7c4028c00e34790f560923d6 YogaKit: f782866e155069a2cca2517aafea43200b01fd5a -PODFILE CHECKSUM: 41176d3adc18f246bc5353c7e0ab01ff73feadfe +PODFILE CHECKSUM: 0eb2bf1b0f7972fc7183f5eac73708f76355c614 COCOAPODS: 1.9.3