【问题标题】:Phonegap Plugman iOS - ERROR: Plugin not foundPhonegap Plugman iOS - 错误:找不到插件
【发布时间】:2013-09-04 23:04:51
【问题描述】:

我使用 Plugman 安装了一个插件,如下所示:

plugman install --platform iOS --project /Users/User/Documents/Projects/MyProject --plugin https://git-wip-us.apache.org/repos/asf/cordova-plugin-splashscreen.git

Plugman 说安装成功。

然而,在构建项目时,xCode 输出显示:

CDVPlugin 类 CDVSplashScreen (pluginName: splash screen) 没有 存在。

[CDVTimer][启动画面] 1.785994ms

CDVPlugin 类 CDVSplashScreen (pluginName: SplashScreen) 没有 存在。

错误:未找到插件“SplashScreen”,或者不是 CDVP 插件。查看 config.xml 中的插件映射。

第二个错误可能是因为我正在尝试使用 javascript 调用 Splashscreen 插件,但我的项目中的两个位置确实有 SplashScreen 文件:

MyProject/cordova/plugins/org.apache.cordova.core.splashscreen/

MyProject/MyProject.xcode/plugins/org.apache.cordova.core.splashscreen/CDVSplashScreen.h MyProject/MyProject.xcode/plugins/org.apache.cordova.core.splashscreen/CDVSplashScreen.m

因此,MyProject 看起来像这样:

  • MyProject/cordova
  • MyProject/CordovaLib
  • 我的项目/我的项目
  • MyProject/SpendToday.xcodeproj
  • 我的项目/www

如果没有相同的问题,我无法安装任何其他插件。有人有什么想法吗?

我正在使用不带 CLI 的 Phonegap 3.0(从 Phonegap 2.4 升级)

【问题讨论】:

    标签: ios xcode cordova


    【解决方案1】:

    在 xcode 中,我导航到 MyProject/MyProject/Plugins

    找到了

    • /CDVSplashScreen.h
    • /CDVSplashScreen.m
    • /CDVInAppBrowser.h
    • /CDVInAppBrowser.m

    就在根目录中。所以我选择删除(仅引用),重新添加文件系统中的 SplashScreen 文件夹。

    现在文件夹如下所示:

    • /org.apache.cordova.core.splashscreen/CDVSplashScreen.h
    • /org.apache.cordova.core.splashscreen/CDVSplashScreen.m
    • /CDVInAppBrowser.h
    • /CDVInAppBrowser.m

    现在 SplashScreen 可以工作了!

    【讨论】:

    • inapp 浏览器也有同样的问题。甚至尝试删除插件并将其添加回来,但没有成功。按照这些步骤将其从 xcode 项目中删除并将其添加回来,然后效果很好!谢谢!
    • 必须手动删除文件并添加整个文件夹才能解决问题。男孩真是一场噩梦,谢谢你的帮助。这是在 xCode 6.0.1 FWIW 上。
    猜你喜欢
    • 2013-08-26
    • 1970-01-01
    • 1970-01-01
    • 2018-06-23
    • 2012-04-17
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多