安装我的 react-native 项目时出现此错误-
/Users/username/.rvm/scripts/rvm: line 12: uname: command not found
/Users/username/.rvm/scripts/rvm: line 29: ps: command not found
/Users/username/Desktop/Applications/SegmentTestApp/ios/Pods/../../node_modules/react-native/React/FBReactNativeSpec/../../scripts/generate-specs.sh:
line 27: readlink: command not found
/Users/username/Desktop/Applications/SegmentTestApp/ios/Pods/../../node_modules/react-native/React/FBReactNativeSpec/../../scripts/generate-specs.sh:
line 27: dirname: command not found
/Users/username/Desktop/Applications/SegmentTestApp/ios/Pods/../../node_modules/react-native/React/FBReactNativeSpec/../../scripts/generate-specs.sh:
line 27: cd: : No such file or directory Command PhaseScriptExecution
failed with a nonzero exit code
这是我的~/.zshrc文件-
export PATH=$PATH:$ANDROID_HOME/tools
export PATH=$PATH:$ANDROID_HOME/platform-tools
export PATH="/usr/local/opt/coreutils/libexec/gnubin:$PATH"
环境 -
❯ echo $PATH
/Users/<username>/.rvm/gems/ruby-3.0.0/bin:/Users/<username>/.rvm/gems/ruby-3.0.0@global/bin:/Users/<username>/.rvm/rubies/ruby3.0.0/bin:/usr/local/opt/coreutils/libexec/gnubin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/Apple/usr/bin:/Applications/Wireshark.app/Contents/MacOS:/Applications/Postgres.app/Contents/Versions/latest/bin:/Users/<username>/Library/Android/sdk/emulator:/Users/<username>/Library/Android/sdk/tools:/Users/<username>/Library/Android/sdk/platform-tools:/Users/<username>/.rvm/bin