chore(dart/transform): Create targets for serving transformed Dart code

- Allow pub (build|serve) to specify mode
- Update pubbuild.js & pubserve.js to allow the caller to provide a `mode` value.
- Update settings to allow the di benchmark to be transformed to run statically.
This commit is contained in:
Tim Blasi
2015-04-06 14:48:07 -07:00
parent 1a99090b45
commit 42c0171b40
5 changed files with 35 additions and 37 deletions

View File

@ -3,7 +3,9 @@ var spawn = require('child_process').spawn;
module.exports = function(gulp, plugins, config, module) {
return function() {
return util.streamToPromise(spawn(config.command, ['serve'], {
var pubMode = config.mode || 'debug';
var pubArgs = ['serve', '--mode', pubMode];
return util.streamToPromise(spawn(config.command, pubArgs, {
cwd: config.path, stdio: 'inherit'
}));
};