문제

When I install an Android specific plugin using plugman it adds asset files to platforms/android/asstes/www/ which is cleared on every cordova prepare cli command and I have to manually add them back.

Is there any way to make plugman to copy them to merges/android/ or platforms/android/platform_www/ instead so that I don't need to copy them manually after every prepare?

도움이 되었습니까?

해결책

Unless you have very specific needs (you don't want to use the CLI at all, or you need a bugfix or feature in a version of plugman that is incompatible with your version of cordova CLI), the best way to install all plugins in cordova is via the CLI:

cordova plugin add https://github.com/phonegap/phonegap-plugin-fast-canvas

The CLI uses plugman under the covers, but handles different asset directories, etc.

You can install plugins that are android only or ios only with cordova plugins.

다른 팁

You can use the /merges folder with CLI: 1) install the plugin via plugman 2) copy the /plugins folder to /merges/android/yourplugin 3) next time you run "cordova prepare" or "cordova build" or "cordova run" it will keep that folder

UPDATE :: If you are using phonegap-plugin-fast-canvas on Cordova 3.0+ build will fail because of a few naming issues

I've proposed to the main git the fix and you can also find it on my fork https://github.com/Davidx7/phonegap-plugin-fast-canvas

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top