[
https://issues.apache.org/jira/browse/CB-10761?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15249574#comment-15249574
]
ASF GitHub Bot commented on CB-10761:
-------------------------------------
Github user vladimir-kotikov commented on a diff in the pull request:
https://github.com/apache/cordova-lib/pull/428#discussion_r60380149
--- Diff: cordova-lib/src/cordova/restore-util.js ---
@@ -112,7 +112,10 @@ function installPluginsFromConfigXML(args) {
// assume it is the location to install from.
var pluginSpec = pluginEntry.spec;
pluginName = pluginEntry.name;
- var installFrom = semver.validRange(pluginSpec, true) ? pluginName
+ '@' + pluginSpec : pluginSpec;
+ var installFrom = (pluginSpec && semver.validRange(pluginSpec,
true)) ?
--- End diff --
Updated
> cordova prepare does not restore saved plugins with no version
> --------------------------------------------------------------
>
> Key: CB-10761
> URL: https://issues.apache.org/jira/browse/CB-10761
> Project: Apache Cordova
> Issue Type: Bug
> Components: CordovaLib
> Reporter: Richard B Knoll
> Labels: reproduced, triaged
>
> If you give a plugin element in config.xml but do not give the {{spec}}
> attribute like so:
> {code}
> <plugin name="cordova-plugin-inappbrowser" />
> {code}
> Then when you run {{cordova prepare}} the CLI will not install the plugin but
> will print out a message saying that it is installing it.
> {code}
> $ cordova prepare
> Discovered plugin "cordova-plugin-inappbrowser" in config.xml. Installing
> to the project
> {code}
> Giving the {{spec}} attribute causes the same message but the plugin will
> actually be installed. I'm not sure what the intended behavior is, but we
> need to fix it and add some test cases.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]