본문 바로가기
개발일지/개발일지! error out🙅

[react-native]error warn Multiple Podfiles were found

by -제이리 2022. 12. 2.
728x90
320x100

발생상황

터미널에 npx react-native init projectName을 입력하고 새로운 에러와 마주쳤다..^^

 

✖ Installing CocoaPods dependencies (this may take a few minutes)
error warn Multiple Podfiles were found: ios/Podfile,vendor/bundle/ruby/2.7.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/Podfile. Choosing ios/Podfile automatically. If you would like to select a different one, you can configure it via "project.ios.sourceDir". You can learn more about it here: https://github.com/react-native-community/cli/blob/master/docs/configuration.md

✖ Installing CocoaPods dependencies (this may take a few minutes)
error Error: Looks like your iOS environment is not properly set. Please go to https://reactnative.dev/docs/next/environment-setup and follow the React Native CLI QuickStart guide for macOS and iOS.
Error: Error: Looks like your iOS environment is not properly set. Please go to https://reactnative.dev/docs/next/environment-setup and follow the React Native CLI QuickStart guide for macOS and iOS.

 

stackoverflow에서 원인을 찾았는데 CLI tool을 올바르게 설정하지 않아서라고 한다. Xcode의 툴설정이 기본설정이 이미 되어있음에도 안되어있다는게 이유.. 답변자도 이상하다고 한다.. 

 

참고원글


 

해결방법

 

1. Xcode에 들어가 command + , 을 눌러 환경설정창을 연다.

2. Locations 탭에 들어가 Comman Line Tools의 옵션부분을 클릭한다. 

 

기본설정이 된것처럼 보여도 한번 만져줘야지 적용이 되는것 같다. 🤷 

 


 

드 디 어 init 완료....

 

728x90
320x100

댓글