简体   繁体   中英

react-native init causing build fail out of box

Using react-native init <projectName> , then npm install results in a build fail with error :

Command /bin/sh failed with exit code 127

and message:

 ../node_modules/react-native/packager/react-native-xcode.sh: line 36: react-native: command not found
Command /bin/sh failed with exit code 127

Have installed react-native both locally, and globally to no avail.

Has anyone run into this issue and know how to solve?

The hack explained here works: https://github.com/facebook/react-native/issues/3948

Add source ~/.bash_profile to the beginning of react-native-xcode.sh

Apparently, fixed in 0.16.0-rc ! https://github.com/facebook/react-native/commit/9a64f17de84e50a4fc60f1b96168aa61925934a8

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM