Newsletter
Join the Community
Subscribe to our newsletter for the latest news and updates
Code examples for a 16-part Gulp.js tutorial series covering build automation, Sass/PostCSS, Jekyll, and deployment.
Gulp.js Tutorial is a free, open-source code repository that accompanies a 16-part blog series on stefanimhoff.de by Stefan Imhoff, teaching how to create a complete Gulp build pipeline for a Jekyll static site.
The Gulp.js Tutorial is a companion code repository for a step-by-step blog series on stefanimhoff.de, written by Stefan Imhoff. It takes a Jekyll project with assets such as Sass/SCSS, JavaScript, images, and fonts, and processes them through a Gulp pipeline to produce an optimized static website. The project runs on Node.js, uses Gulp as the task runner, and centralizes configuration in gulp/config.js. The repository includes example files, a complete build setup, and instructions for installing Node with nvm, Yarn, Bundler, Bower, and Fontcustom.
yarn start builds assets and the Jekyll site, starts a local server, and automatically reloads when files change.ruby-sass branch provides the older Sass/Compass version.yarn run publish optimizes all assets and runs a production Jekyll build; yarn run deploy copies the generated files to a server via Rsync.master and ruby-sass branches.yarn start and get a local server with live reload, SCSS/PostCSS compilation, and JavaScript bundling.yarn run publish to optimize CSS, JavaScript, images, and HTML, and produce a versioned build for release.gulp/config.js and run yarn run deploy to upload the generated site to your server.The repository is organized around the 16 tutorial posts, each adding a new capability to the Gulpfile. After cloning, install dependencies with bundle, bower install, and npm install (or Yarn). Then edit gulp/config.js to set your deployment target and other project-specific settings. The tutorials are ordered from setup through development server, build tasks, CSS generation, JavaScript bundling, image processing, linting, production optimization, revisioning, and finally deployment.
ruby-sass branch for legacy workflows.The tutorial instructs you to install Node version 6.3.1 using nvm. If you are using a newer Node version, you may need to update some Gulp plugins or the configuration, but the general Gulp workflow will still work.
Yes. Although the current master branch uses PostCSS, the repository has a ruby-sass branch where you can see the original Sass and Compass setup. You can switch to that branch if you prefer the older approach.
Run yarn run deploy. This command uses Rsync to copy the generated files to your server. You must first set the hostname, username, and destination values in gulp/config.js.
start, publish, and deploy?yarn start runs a development server with live reload and file watching. yarn run publish creates an optimized production build (minifies assets, generates WebP, and adds hashed filenames). yarn run deploy builds the production version and then uploads it to your server via Rsync.
Yes. The tutorial includes the Gulp.js logo, a pattern from Subtle Patterns, and SVG/PNG icons from the IcoMoon Icon Pack to demonstrate the image and font processing tasks.
