-
Notifications
You must be signed in to change notification settings - Fork 8
/
gulpfile.js
26 lines (20 loc) 路 741 Bytes
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
const gulp = require('gulp');
const util = require('util');
const exec = util.promisify(require('child_process').exec);
const srcPath = './.gulp/';
function execNode(command) {
return exec(`node --harmony ${command}`).then((res) => {
if (res.stdout) {
console.log(res.stdout);
}
return res.stdout;
});
}
gulp.task('build_theme', () => execNode(`${srcPath}build-theme.js`));
gulp.task('build_schemes', () => execNode(`${srcPath}build-schemes.js`));
gulp.task('build_icons', () => execNode(`${srcPath}build-icons.js`));
gulp.task('build_all', () => execNode(`${srcPath}build-all.js`));
gulp.task('watch', () => {
gulp.watch('.gulp/**/*', gulp.series('build_all'));
});
gulp.task('default', gulp.series('watch'));