diff --git a/file2modulename.js b/file2modulename.js index 1beb1fff37..6f8dbd2aa2 100644 --- a/file2modulename.js +++ b/file2modulename.js @@ -1,5 +1,5 @@ function file2moduleName(filePath) { - return filePath + return filePath.replace(/\\/g, '/') // module name should be relative to `modules` and `tools` folder .replace(/.*\/modules\//, '') .replace(/.*\/tools\//, '') diff --git a/gulpfile.js b/gulpfile.js index 3bb0d5fb8e..5e2006f2be 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -330,7 +330,7 @@ gulp.task('serve', function() { }); gulp.task('examples/pub.serve', function(done) { - spawn('pub', ['serve'], {cwd: 'build/dart/examples', stdio: 'inherit'}) + spawn(PUB_CMD, ['serve'], {cwd: 'build/dart/examples', stdio: 'inherit'}) .on('done', done); });