上QQ阅读APP看书,第一时间看更新
Understanding the gulpfile
In the gulpfile, we are performing the following instructions:
- Import Gulp and Gulp-shell.
- Create tasks with shell.task as the function to execute.
- shell.task can execute a command-line instruction. Keep your shell commands inside that function.
- Add a watch task for watching source files. The task list will be executed when files are modified.
- Create a default task for running. Add a watch to it.
Gulp is a great tool for these kinds of use cases. So, please go through the official documentation of Gulp at http://gulpjs.com/.