I have self written plugin into my-plugin/plugin
.
I install it with cordova plugin add my-plugin/plugin
. Then it appears under plugins/
and in my Android project.
Now I want to make some changes in this plugin, but I don't know how to deploy these changes into my Android project.
My current workaround is cordova plugin rm com.my.plugin
and then cordova plugin add my-plugin/plugin
.
Is there any better way?
$ cordova -v
3.2.0-0.2.0
You could try just cordova plugin add my-plugin/plugin and skip the remove it seems to do the update even though it reports that its already installed.
Like you all I assumed (or read somewhere, not sure which) that cordova auto updated the plugins when building, I dont think that is the case.
With Phonegap 3.4 there are now hooks which can run based on commands such as before_build, using those you can run a script which updates your plugins each time you run build.
See this blog for more info http://devgirl.org/2013/11/12/three-hooks-your-cordovaphonegap-project-needs/
I just had the same question and tried to find any documentation on updating cordova apps but i seems like there is no documentation at all.
So i did it with rm
and add
afterwards.
But i can't believe that there is no better way though :(
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With