You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Jesper van den Ende (JIRA)" <ji...@apache.org> on 2018/03/04 19:26:00 UTC

[jira] [Updated] (CB-13949) cordova prepare doesn't install the correct plugin versions

     [ https://issues.apache.org/jira/browse/CB-13949?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jesper van den Ende updated CB-13949:
-------------------------------------
    Description: 
according to the documentation at [https://cordova.apache.org/docs/en/latest/platform_plugin_versioning_ref/#plugin-versioning] plugins should install the version from either config.xml or package.json. However, the latest version is always installed instead.

How to reproduce:
{noformat}
cordova create test
cd test
cordova platform add android
cordova plugin add cordova-plugin-splashscreen@4.0.0{noformat}
Note how
{code:java}
cordova plugin ls{code}
Shows that version 4.0.0 is installed. Also config.xml and package.json both indicate that 4.0.0 is installed.

Now delete the 'platforms' and 'plugins' folder and run
{noformat}
cordova prepare{noformat}
Note how config.xml and package.json still indicate that 4.0.0 installed, however when running
{noformat}
cordova plugin ls{noformat}
it shows
{noformat}
cordova-plugin-splashscreen 4.1.0 "Splashscreen"
cordova-plugin-whitelist 1.3.3 "Whitelist"{noformat}
 
 perhaps I'm missing something, though my understanding is that when `cordova prepare` is run, all plugins and platforms will be installed with their version as listed in package.json and config.xml.

 
{noformat}
cordova plugin rm cordova-plugin-splashscreen
cordova plugin add cordova-plugin-splashscreen@4.0.0{noformat}
Installs the correct version again, but that kind of defeats the purpose of cordova prepare.

  was:
according to the documentation at [https://cordova.apache.org/docs/en/latest/platform_plugin_versioning_ref/#plugin-versioning] plugins should install the version from either config.xml or package.json. However, the latest version is always installed instead.

How to reproduce:
{noformat}
cordova create test
cd test
cordova platform add android
cordova plugin add cordova-plugin-splashscreen@4.0.0{noformat}
Note how
{code:java}
cordova plugin ls{code}
Shows that version 4.0.0 is installed. Also config.xml and package.json both indicate that 4.0.0 is installed.

Now delete the 'platforms' and 'plugins' folder and run
{noformat}
cordova prepare{noformat}
Note how config.xml and package.json still indicate that 4.0.0 installed, however when running
{noformat}
cordova plugin ls{noformat}
it shows
{noformat}
cordova-plugin-splashscreen 4.1.0 "Splashscreen"
cordova-plugin-whitelist 1.3.3 "Whitelist"{noformat}
 
perhaps I'm missing something, though my understanding is that when `cordova prepare` is run, all plugins and platforms will be installed with their version as listed in package.json and config.xml.


> cordova prepare doesn't install the correct plugin versions
> -----------------------------------------------------------
>
>                 Key: CB-13949
>                 URL: https://issues.apache.org/jira/browse/CB-13949
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: cordova-cli
>    Affects Versions: cordova@8.0.0
>         Environment: Mac OS,
> Cordova 8.0.0
> npm 3.10.3
>            Reporter: Jesper van den Ende
>            Priority: Major
>              Labels: cordova-cli, plugin, prepare, version
>
> according to the documentation at [https://cordova.apache.org/docs/en/latest/platform_plugin_versioning_ref/#plugin-versioning] plugins should install the version from either config.xml or package.json. However, the latest version is always installed instead.
> How to reproduce:
> {noformat}
> cordova create test
> cd test
> cordova platform add android
> cordova plugin add cordova-plugin-splashscreen@4.0.0{noformat}
> Note how
> {code:java}
> cordova plugin ls{code}
> Shows that version 4.0.0 is installed. Also config.xml and package.json both indicate that 4.0.0 is installed.
> Now delete the 'platforms' and 'plugins' folder and run
> {noformat}
> cordova prepare{noformat}
> Note how config.xml and package.json still indicate that 4.0.0 installed, however when running
> {noformat}
> cordova plugin ls{noformat}
> it shows
> {noformat}
> cordova-plugin-splashscreen 4.1.0 "Splashscreen"
> cordova-plugin-whitelist 1.3.3 "Whitelist"{noformat}
>  
>  perhaps I'm missing something, though my understanding is that when `cordova prepare` is run, all plugins and platforms will be installed with their version as listed in package.json and config.xml.
>  
> {noformat}
> cordova plugin rm cordova-plugin-splashscreen
> cordova plugin add cordova-plugin-splashscreen@4.0.0{noformat}
> Installs the correct version again, but that kind of defeats the purpose of cordova prepare.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org