A toolkit to automate & enhance your workflow
The streaming build system
Follow our Quick Start guide.
Find out about all our work-in-progress and outstanding issues at https://github.com/orgs/gulpjs/projects.
Check out the Getting Started guide and API docs on our website!
Excuse our dust! All other docs will be behind until we get everything updated. Please open an issue if something isn't working.
gulpfile.jsThis file will give you a taste of what gulp does.
…Gulp provides a wrapper that will be loaded in your ESM code, so you can name your gulpfile as gulpfile.mjs or with "type": "module" specified in your package.json file.
And here's the same sample from above written in ESNext.
…You can filter out unchanged files between runs of a task using
the gulp.src function's since option and gulp.lastRun:
const paths = {
...
images: {
src: 'src/images/**/*.{jpg,jpeg,png}',
dest: 'build/img/'
}
}
function images() {
return gulp.src(paths.images.src, {since: gulp.lastRun(images)})
.pipe(imagemin())
.pipe(gulp.dest(paths.images.dest));
}
function watch() {
gulp.watch(paths.images.src, images);
}Task run times are saved in memory and are lost when gulp exits. It will only
save time during the watch task when running the images task
for a second time.
Anyone can help make this project better - check out our Contributing guide!
Normalize repository
gulp.src() doesn't like windows paths with paranthesis in the name?
Gulp5: `gulpfile.ts` Not Found, `gulpfile.js` AOK
Glob order matters for negated wildcard paths when it shouldn't
ENOENT on nonexistant glob directory with gulp v5.0.1
Error resolving symlink after upgrade to Gulp v5
Upgrade from Gulp 4.0.2 to 5.0.0 with Node V20-LTS is missing bundled js files
src() doesn't work with wildcards (4.0.2 -> 5.0.0)
Corruption of image files during migration or optimization
Pipeline errors are not properly handled in Gulp v5