这是在Mac,我是一个绝对的新手 . 我在Pluralsight跟随Nativescript课程,以加快应用程序开发的速度 . 我按照课程规定安装了所有先决条件(Xcode,nativescript,typescript等) .
我创建了一个非常简单的nativescript项目,在xml页面中有一个按钮 . 但是,当我在终端中运行命令“tns run ios --emulator”时,我收到错误
命令失败:/ bin / sh -c ruby -e "require 'xcodeproj'; Xcodeproj::Config.new('/Users/username/rps-conf/platforms/ios/plugins-debug.xcconfig').merge(Xcodeproj::Config.new('/Users/username/rps-conf/app/App_Resources/iOS/build.xcconfig')).save_as(Pathname.new('/Users/username/rps-conf/platforms/ios/plugins-debug.xcconfig'))"忽略executable-hooks-1.3.2,因为它的扩展未构建 . 尝试:gem pristine executable-hooks --version 1.3.2忽略gem-wrappers-1.2.7因为它的扩展没有构建 . 尝试:gem pristine gem-wrappers --version 1.2.7 /Users/username/.rbenv/versions/2.3.1/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in require': cannot load such file -- xcodeproj (LoadError) from /Users/username/.rbenv/versions/2.3.1/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in
require ' from -e:1:in `'
我有一个编程背景(.Net)所以我想了解究竟是什么问题,而不是盲目地尝试终端中给出的自动指令('try gem pristine etc.')
2 回答
检查NativeScript安装是否正确...如果确定,请尝试
tns doctor
我能够通过卸载节点和ruby并按照此处的高级设置说明手动重新安装所有内容来修复它:docs.nativescript.org/start/ns-setup-os-x