作为我的默认任务,我在运行两个不同的gulp手表时遇到了麻烦。这是我的gulpfile.babel.js
import gulp from "gulp";
import git from "gulp-git";
import ts from "gulp-typescript";
const tsProject = ts.createProject("tsconfig.json");
export function watchTs() {
gulp.watch(
// details omitted...
);
}
export function watchGit() {
gulp.watch(
// details omitted...
);
}
export default function(cb) {
gulp.parallel(watchTs, watchGit);
}这就是当我运行gulp时发生的事情:
master* $ gulp [16:21:52]
[16:21:54] Requiring external module @babel/register
[16:21:55] Using gulpfile ~/Documents/github/screeps/gulpfile.babel.js
[16:21:55] Starting 'default'...
[16:21:55] The following tasks did not complete: default
[16:21:55] Did you forget to signal async completion?我可以通过运行:gulp watchTs & gulp watchGit获得正确的结果。为什么这不起作用?
发布于 2020-03-06 07:32:45
我想通了。我认为缺省值需要是我定义的函数,但这是可行的。
export default gulp.parallel(watchTs, watchGit);我仍然不能百分之百确定为什么另一种方法不起作用。任何帮助我理解的反馈都将受到欢迎。
https://stackoverflow.com/questions/60555488
复制相似问题