Skip to content

Instantly share code, notes, and snippets.

@xizhibei
Created January 29, 2016 07:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xizhibei/019a990f83fab0a5c1cf to your computer and use it in GitHub Desktop.
Save xizhibei/019a990f83fab0a5c1cf to your computer and use it in GitHub Desktop.
gulpfile
const gulp = require('gulp'),
gulpLoadPlugins = require('gulp-load-plugins');
const $ = gulpLoadPlugins();
gulp.task('babel', () => {
return gulp.src('src/**/*.js')
.pipe($.babel())
.pipe(gulp.dest('dist'));
});
gulp.task('server', () => {
$.nodemon({
script: 'src/app.js',
ext: 'js,json',
execMap: {
js: 'babel-node'
},
ignore: [
'node_modules/*',
'src/bin/*',
'test/*',
'gulpfile.js',
],
env: {
'NODE_ENV': 'local',
'DEBUG': 'mquery',
},
// nodeArgs: ['--debug'],
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment