离子3 - 无法使用最新的xcode为ios安装onesignal插件

时间:2018-01-13 03:12:42

标签: ios xcode plugins ionic3 onesignal

我无法为onesignal插件创建添加ios平台。用android构建它很好。

我这样做了:

$ ionic cordova platform add ios

以下错误失败。

apple-ios version check failed ("/Users/megasap/Documents/project/railerdotcom/railercom_parent/platforms/ios/cordova/apple_ios_version"), continuing anyways.

Failed to install 'onesignal-cordova-plugin': undefined

Failed to restore plugin "onesignal-cordova-plugin" from config.xml. You might need to try adding it again. Error: /Users/megasap/.rbenv/shims/pod: line 21: /usr/local/Cellar/rbenv/1.0.0/libexec/rbenv: No such file or directory

--save flag or autosave detected

Saving ios@~4.5.4 into config.xml file ...
[ERROR] Exception: 

此处完全执行和错误: https://gist.github.com/axilaris/a926c54eb515bef5eb2f7019e36aa40f

这曾经工作,我只是更新到最新的xcode 9.2来编译其他东西。使用最新的xcode有问题吗?

2 个答案:

答案 0 :(得分:5)

安装并更新cocoapods解决问题

sudo gem install cocoapods pod setup

您可能需要rmadd ios平台才能使其正常运行

答案 1 :(得分:1)

实际问题在于:

  

错误:/Users/megasap/.rbenv/shims/pod:第21行:/usr/local/Cellar/rbenv/1.0.0/libexec/rbenv:没有这样的文件或目录

只需更新/安装cocoapods到最新版本,因为您的xcode也已更新。

sudo gem install cocoapods