forked from NathanWalker/angular-seed-advanced
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gulpfile.ts
27 lines (21 loc) · 756 Bytes
/
gulpfile.ts
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
27
import * as gulp from 'gulp';
import * as util from 'gulp-util';
import * as runSequence from 'run-sequence';
import Config from './tools/config';
import { loadTasks, loadCompositeTasks } from './tools/utils';
loadTasks(Config.SEED_TASKS_DIR);
loadTasks(Config.PROJECT_TASKS_DIR);
loadCompositeTasks(Config.SEED_COMPOSITE_TASKS, Config.PROJECT_COMPOSITE_TASKS);
// --------------
// Clean dev/coverage that will only run once
// this prevents karma watchers from being broken when directories are deleted
let firstRun = true;
gulp.task('clean.once', (done: any) => {
if (firstRun) {
firstRun = false;
runSequence('check.tools', 'clean.dev', 'clean.coverage', done);
} else {
util.log('Skipping clean on rebuild');
done();
}
});