microsoft / taco-team-build

taco-team-build is a node module designed to avoid common pitfalls when building Cordova apps in a Team or Continuous Integration (CI) environment
MIT License
26 stars 19 forks source link

TACO Installs and uses Cordova 6.0.0 when 5.4.1 is required #18

Closed gmaughan closed 8 years ago

gmaughan commented 8 years ago

When building a Cordova app using Gulp, the TACO tools now install and use Cordova 6.0.0 rather than the required 5.4.1. This started to occur as soon as Cordova 6.0.0 was released in late January.

My taco.json file specifies 5.4.1 as the version of Cordova to use.

{
  "cordova-cli": "5.4.1"
}

When building in Visual Studio 2015, Cordova 5.4.1 is correctly installed and used.

The problem only occurs when building on the command line or from our Jenkins server, both of which use gulp to build. All of our automated builds started to fail after Cordova 6.0.0 was released.

My package.json references the latest version of gulp and taco-team-build.

{
  "devDependencies": {
    "gulp": "latest",
    "gulp-typescript": "latest",
    "gulp-sourcemaps": "latest",
    "gulp-less": "latest",
    "gulp-cssmin": "latest",
    "gulp-rename": "latest",
    "gulp-file": "latest",
    "semver": "latest",
    "del": "latest",
    "gulp-bump": "latest",
    "gulp-cheerio": "latest",
    "run-sequence": "latest",
    "yargs": "latest",
    "taco-team-build": "latest",
    "browser-sync": "~2.11.1"
  }
}

How can I force the build to use 5.4.1? Is this a problem with taco-team-build?

PS. this is a copy of the same question on Stack Overflow. Getting no response and need to build soon!

Chuxel commented 8 years ago

I replied to your Stack question.

Chuxel commented 8 years ago

Reopening - There may be a bug here. @ryuyu is taking a look now. Thanks for reporting! Looks like a gap in our test matrix.

gmaughan commented 8 years ago

Adding the following to my gulpfile.js successfully works around the issue:

var cordovaBuild = require("taco-team-build");
cordovaBuild.configure({
    moduleVersion: "5.4.1"
});

Thanks. Glenn.

Chuxel commented 8 years ago

Glad the workaround kept you going! Peter's PR should fix taco.json problem so we'll get a break fix release going to get that out as well.