Skip to content

Instantly share code, notes, and snippets.

@callstack-bot
Created October 7, 2022 11:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save callstack-bot/b6f07259a08e8af8f4b678266c724fd4 to your computer and use it in GitHub Desktop.
Save callstack-bot/b6f07259a08e8af8f4b678266c724fd4 to your computer and use it in GitHub Desktop.
- 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/scripts/react_native_pods'
+ require_relative '../../../node_modules/@react-native-community/cli-platform-ios/native_modules'
target 'ExampleApp' do
...
@hetmann
Copy link

hetmann commented Feb 23, 2023

@callstack-bot You forgot to mention to update post_install

post_install do |installer|
    react_native_post_install(
      installer,
      react_native_path = "../../../node_modules/react-native", # <- add this
      # Set `mac_catalyst_enabled` to `true` in order to apply patches
      # necessary for Mac Catalyst builds
      :mac_catalyst_enabled => false
    )
    __apply_Xcode_12_5_M1_post_install_workaround(installer)
  end

I my situation I got an error when generating Pods project

Generating Pods project
[!] An error occurred while processing the post-install hook of the Podfile.

No such file or directory @ rb_sysopen - /Users/hetmann/[...redacted..]/mobile/example/ios/../node_modules/react-native/package.json

@DimitarNestorov
Copy link

You forgot to mention to update post_install

@okwasniewski

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment