【发布时间】:2015-07-25 19:01:48
【问题描述】:
当我构建我的cordova 项目时,我收到一条警告消息:
缺少文件: /home/vijay/workspace/Repos_temp/QuickTraq_Android/plugins/nl.x-services.plugins.toast/plugin.xml
缺少文件: /home/vijay/workspace/Repos_temp/QuickTraq_Android/plugins/cordova-plugin-device-rotation-vector/plugin.xml
当我添加插件或删除插件时也会发生这种情况。
当我添加插件或构建项目时,这只是一个警告,但是当我删除插件时,会发生错误
错误:ENOENT,没有这样的文件或目录 '/home/vijay/workspace/Repos_temp/QuickTraq_Android/plugins/com.grumpysailor.cordova-plugin-device-rotation-vector/plugin.xml' 在 Object.fs.openSync (fs.js:439:18) 在 Object.fs.readFileSync (fs.js:290:15) 在 Object.module.exports.parseElementtreeSync (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/util/xml-helpers.js:121:27) 在/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/util/dependencies.js:56:35 在 Array.forEach (本机) 在 Object.module.exports.package.generateDependencyInfo (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/util/dependencies.js:53:45) 在 runUninstallPlatform (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/uninstall.js:218:53) 在 Function.module.exports.uninstallPlatform (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/plugman/uninstall.js:81:12) 在/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/plugin.js:205:58 在 _fulfilled (/usr/local/lib/node_modules/cordova/node_modules/q/q.js:787:54)
我的插件删除失败..有没有办法解决这个问题?
【问题讨论】:
-
如果您使用了 Cordova 的命令,您能否再次尝试
add插件(使用phonegap local plugin add)。如果这仍然不起作用,请尝试使用npm cache clean清理 npm 的缓存并重新安装 Cordova/Phonegap。 -
我试过 npm cache clean 。我不想重新安装cordova 有解决办法吗??
-
请问您为什么不愿意重新安装 Cordova?当您再次尝试
add插件时会发生什么? -
我有一个工作环境,我担心可能会发生一些事情。所以我字体更喜欢重新安装。当我添加插件时它说已经存在。
标签: android cordova phonegap-plugins phonegap-build cordova-plugins