cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stevengill <>
Subject [GitHub] cordova-lib pull request #518: CB-12021 : --fetch should use dependency vers...
Date Sat, 18 Feb 2017 01:15:14 GMT
Github user stevengill commented on a diff in the pull request:
    --- Diff: cordova-lib/src/cordova/plugin.js ---
    @@ -414,13 +414,15 @@ function determinePluginTarget(projectRoot, cfg, target, fetchOptions)
         // it does not satisfy.
         if(parsedSpec.version) {
             if(pkgJson && pkgJson.dependencies && pkgJson.dependencies[parsedSpec.package])
    -            var noSymbolVersion;
    +            var noSymbolVersion = parsedSpec.version;
                 if (parsedSpec.version.charAt(0) === '^' || parsedSpec.version.charAt(0)
=== '~') {
                     noSymbolVersion = parsedSpec.version.slice(1);
    -            if (!semver.satisfies(noSymbolVersion, pkgJson.dependencies[parsedSpec.package]))
    +            if (pkgJson.dependencies[parsedSpec.package] === parsedSpec.version) {
    --- End diff --
    I think we still want to do the semver check too. First start with outer if that checks
if `parsedSpec.version` is a directory or url,  if it is, do this check  to see if `pkgJson.dependencies[parsedSpec.package]
!== parsedSpec.version`. If that is true, then you want to update package.json (assuming
=== true)
    On that outer if that checks if it is a dir or url, add a else if where you check for

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message