Permalink
Browse files

[TIMOB-11919] Added support for the new Titanium module conflict dete…

…ction.
  • Loading branch information...
1 parent 93b8c8a commit 7ac1559cf7367ad7ef1ef8f3388f55f01124275d @cb1kenobi cb1kenobi committed Jan 18, 2013
Showing with 18 additions and 0 deletions.
  1. +9 −0 iphone/cli/commands/_build.js
  2. +9 −0 mobileweb/cli/commands/_build.js
@@ -1530,6 +1530,15 @@ build.prototype = {
process.exit(1);
}
+ if (modules.conflict.length) {
+ this.logger.error(__('Found conflicting Titanium modules:'));
+ modules.conflict.forEach(function (m) {
+ this.logger.error(' ' + __('Titanium module "%s" requested for both iOS and CommonJS platforms, but only one may be used at a time.', m.id));
+ }, this);
+ this.logger.log();
+ process.exit(1);
+ }
+
this.modules = modules.found;
modules.found.forEach(function (module) {
@@ -354,6 +354,15 @@ build.prototype = {
process.exit(1);
}
+ if (modules.conflict.length) {
+ this.logger.error(__('Found conflicting Titanium modules:'));
+ modules.conflict.forEach(function (m) {
+ this.logger.error(' ' + __('Titanium module "%s" requested for both Mobile Web and CommonJS platforms, but only one may be used at a time.', m.id));
+ }, this);
+ this.logger.log();
+ process.exit(1);
+ }
+
modules.found.forEach(function (module) {
var moduleDir = module.modulePath,
pkgJson,

0 comments on commit 7ac1559

Please sign in to comment.