diff options
| author | Aya Morisawa <AyaMorisawa4869@gmail.com> | 2019-01-29 16:31:05 +0900 |
|---|---|---|
| committer | Aya Morisawa <AyaMorisawa4869@gmail.com> | 2019-01-29 17:10:16 +0900 |
| commit | 8a3e26cdb8e5b8c6fda4ba1ac6bd06efd627455d (patch) | |
| tree | f7627116b784e455afdda73055094b26f7c21a3b | |
| parent | Use parallel and task to specify dependencies (diff) | |
| download | sharkey-8a3e26cdb8e5b8c6fda4ba1ac6bd06efd627455d.tar.gz sharkey-8a3e26cdb8e5b8c6fda4ba1ac6bd06efd627455d.tar.bz2 sharkey-8a3e26cdb8e5b8c6fda4ba1ac6bd06efd627455d.zip | |
Sort tasks by topological ordering
| -rw-r--r-- | gulpfile.ts | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/gulpfile.ts b/gulpfile.ts index 9a674a3eaf..56949a7067 100644 --- a/gulpfile.ts +++ b/gulpfile.ts @@ -32,14 +32,6 @@ if (isDebug) { console.warn(chalk.yellow.bold(' built script will not be compressed.')); } -gulp.task('build', gulp.parallel( - 'build:ts', - 'build:copy', - 'build:client', - 'locales', - 'doc' -)); - gulp.task('build:ts', () => { const tsProject = ts.createProject('./tsconfig.json'); @@ -66,8 +58,6 @@ gulp.task('build:copy', gulp.parallel('build:copy:views', () => ]).pipe(gulp.dest('./built/')) )); -gulp.task('test', gulp.task('mocha')); - gulp.task('lint', () => gulp.src('./src/**/*.ts') .pipe(tslint({ @@ -93,6 +83,8 @@ gulp.task('mocha', () => } as any)) ); +gulp.task('test', gulp.task('mocha')); + gulp.task('clean', cb => rimraf('./built', cb) ); @@ -101,14 +93,6 @@ gulp.task('cleanall', gulp.parallel('clean', cb => rimraf('./node_modules', cb) )); -gulp.task('default', gulp.task('build')); - -gulp.task('build:client', gulp.parallel( - 'build:client:script', - 'build:client:styles', - 'copy:client' -)); - gulp.task('build:client:script', () => { const client = require('./built/client/meta.json'); return gulp.src(['./src/client/app/boot.js', './src/client/app/safe.js']) @@ -154,3 +138,19 @@ gulp.task('doc', () => .pipe((cssnano as any)()) .pipe(gulp.dest('./built/docs/assets/')) ); + +gulp.task('build:client', gulp.parallel( + 'build:client:script', + 'build:client:styles', + 'copy:client' +)); + +gulp.task('build', gulp.parallel( + 'build:ts', + 'build:copy', + 'build:client', + 'locales', + 'doc' +)); + +gulp.task('default', gulp.task('build')); |