Open JDMathew opened 2 years ago
I had a similar problem but solved it by uninstalling cocoapods, by running gem uninstall cocoapods
followed by reinstalling cocoapods with Homebrew brew install cocoapods
. Afterward just running pod install worked fine for me :)
I had a similar problem but solved it by uninstalling cocoapods, by running
gem uninstall cocoapods
followed by reinstalling cocoapods with Homebrewbrew install cocoapods
. Afterward just running pod install worked fine for me :)
Strange because when I setup my mac I did run a gem uninstall cocoapods
and installed it via brew so I shouldn't have lingering gem cocoapods issues but maybe it is the version. I will update cocoapods
via brew and see if it fixes it.
I noticed that you have to run npm install
before you run cd ios && pod install
. I also had to run bundle install
for it to find cocoapods.
I updated to react-native 0.69, when I try to start a new project, the following error raised:
✖ Installing CocoaPods dependencies (this may take a few minutes)
✖ Installing CocoaPods dependencies (this may take a few minutes)
error Error: Failed to install CocoaPods dependencies for iOS project, which is required by this template.
I am using cocoapods from homebrew
@kockok is this during react-native init command?
@kockok is this during react-native init command?
Yes, this is not specific to the --typescript-template
as I get this error even without specifying a template...
~/app: npx react-native init myApp
✔ Downloading template
✔ Copying template
✔ Processing template
✖ Installing CocoaPods dependencies (this may take a few minutes)
✖ Installing CocoaPods dependencies (this may take a few minutes)
error Error: Failed to install CocoaPods dependencies for iOS project, which is required by this template.
Please try again manually: "cd ./myApp/ios && pod install".
CocoaPods documentation: https://cocoapods.org/
I'm getting the same error (0.69) and doesn't seem to be related to cocoapods not being found (and not limited to this template). Doing a manual pod install
in the iOS directory gives the more verbose error below . I get the same results when I drop the --template (so just npx react-native init my app
) so it appears to be an issue with 0.69 and/or react-native-cli 8.0.x. pod install --repo-update
in the ios directory makes everything work.
[!] CocoaPods could not find compatible versions for pod "Flipper-DoubleConversion":
In Podfile:
Flipper-DoubleConversion (= 3.2.0.1)
None of your spec sources contain a spec satisfying the dependency: `Flipper-DoubleConversion (= 3.2.0.1)`.
You have either:
* out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
* mistyped the name or version.
* not added the source repo that hosts the Podspec to your Podfile.
I get same problem
In my other os, can work, but here is not work
how to do in it problem ?
Simply run pod repo update
before creating the react-native app.
Cocoapods holds a list of all pods locally. By executing the command above you refresh that list.
works for me. 🚀
Expected results
If I run
npx react-native init example
then CocoaPods dependencies are installed correctly but runningnpx react-native init example --template react-native-template-typescript
fails on this stepObserved results
even after running
cd ./example/ios && pod install
this still fails