{"id":15637,"library":"gulpfile-config","title":"Gulp Bundler with JSON Configuration","description":"gulpfile-config is a Gulp utility designed to simplify web asset bundling and compilation tasks through a declarative `gulpfile-config.json` file. It abstracts common Gulp tasks, enabling configuration-driven builds for various asset types including HTML, MJML templates, SASS/CSS, and JavaScript, with built-in options for minification. The package also includes basic development server capabilities. It is currently in an early alpha state (version `1.0.0-alpha.23`) and has not seen active development since December 2021, suggesting it is effectively abandoned. Its primary differentiation lies in minimizing boilerplate in `gulpfile.js` by centralizing build logic in a JSON file, intended for use with Gulp CLI version 4.0.0 and older Node.js runtimes (Node 12-17).","status":"abandoned","version":"1.0.0-alpha.23","language":"javascript","source_language":"en","source_url":"git://github.com/actarian/gulpfile-config","tags":["javascript","gulpfile-config","gulp","bundler","module","es6","es2015"],"install":[{"cmd":"npm install gulpfile-config","lang":"bash","label":"npm"},{"cmd":"yarn add gulpfile-config","lang":"bash","label":"yarn"},{"cmd":"pnpm add gulpfile-config","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"This library is primarily designed for CommonJS `gulpfile.js` files where `require` executes the module and registers Gulp tasks. Direct ESM `import` is not natively supported for gulpfiles without additional configuration and may not properly register tasks.","wrong":"import 'gulpfile-config';","symbol":"(Task Registration)","correct":"require('gulpfile-config');"},{"note":"The package exports an instance of `GulpfileConfig` directly via `module.exports` for programmatic access. Use `require` to obtain this instance in CommonJS environments. There is no `default` export for ESM modules.","wrong":"import config from 'gulpfile-config';","symbol":"GulpfileConfigInstance","correct":"const config = require('gulpfile-config');"},{"note":"The `gulpfile-config` package does not expose named exports. All functionality is either triggered by the initial `require` call (task registration) or accessed via methods on the single exported instance (e.g., `require('gulpfile-config').method()`).","wrong":"const { compile, bundle } = require('gulpfile-config');","symbol":"NamedExport"}],"quickstart":{"code":"// 1. Ensure Gulp CLI is installed globally: npm install gulp-cli -g\n\n// 2. Initialize a new project and install dependencies\n//    mkdir my-project && cd my-project\n//    npm init -y\n//    npm install --save-dev gulp@^4.0.0 gulpfile-config@^1.0.0-alpha.23\n\n// 3. Create 'gulpfile.js' in your project root:\n//    const gulp = require('gulp');\n//    require('gulpfile-config'); // This line registers all tasks defined in gulpfile-config.json\n\n// 4. Create 'gulpfile-config.json' in your project root:\n/*\n{\n  \"targets\": {\n    \"browser\": {\n      \"compile\": [\n        { \"input\": \"src/**/*.html\", \"output\": \"dist/\", \"minify\": true },\n        { \"input\": \"src/css/main.scss\", \"output\": \"dist/css/main.css\", \"minify\": true },\n        { \"input\": \"src/js/main.js\", \"output\": \"dist/js/main.js\", \"minify\": true }\n      ]\n    }\n  },\n  \"server\": { \"root\": \"./dist\", \"port\": 3000 }\n}\n*/\n\n// 5. Create example source files in a 'src' directory:\n//    src/index.html:\n/*\n<!DOCTYPE html><html lang=\"en\"><head><meta charset=\"UTF-8\"><meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"><title>Gulp Config Example</title><link rel=\"stylesheet\" href=\"css/main.css\"></head><body><h1>Hello, Gulpfile Config!</h1><script src=\"js/main.js\"></script></body></html>\n*/\n\n//    src/css/main.scss:\n/*\n$primary-color: #3498db; body { font-family: Arial, sans-serif; color: $primary-color; h1 { text-align: center; } }\n*/\n\n//    src/js/main.js:\n/*\ndocument.addEventListener('DOMContentLoaded', () => { console.log('JavaScript loaded and DOM is ready!'); const heading = document.querySelector('h1'); if (heading) { heading.textContent += ' (from JS)'; } });\n*/\n\n// 6. Run Gulp tasks from your terminal in the project root:\n//    To build, serve, and watch: gulp\n//    To build only: gulp build\n//    To build CSS only: gulp buildCss","lang":"javascript","description":"This quickstart demonstrates how to set up a project using `gulpfile-config` to compile HTML, SCSS, and JavaScript, then serve the compiled assets with a development server using `gulp` commands."},"warnings":[{"fix":"Refer to the project's CHANGELOG (if available) for specific changes when updating between alpha versions. Consider pinning to exact alpha versions to avoid unexpected changes.","message":"The package is currently at version `1.0.0-alpha.23`, indicating it is pre-release software. API stability is not guaranteed, and breaking changes may occur without major version bumps.","severity":"breaking","affected_versions":">=1.0.0-alpha.0"},{"fix":"For new projects, consider modern, actively maintained alternatives for asset bundling (e.g., Vite, Webpack, Rollup, Parcel). For existing projects, evaluate the risks of using unmaintained software.","message":"The project appears to be abandoned or unmaintained, with the last commit dating back to December 2021. This means there is no active development, bug fixes, or security updates, making it unsuitable for new projects or production environments.","severity":"gotcha","affected_versions":">=1.0.0-alpha.23"},{"fix":"Ensure `gulp-cli` version 4.0.0 or higher is installed globally. Verify with `gulp --version`.","message":"This utility requires Gulp CLI version 4.0.0 installed globally (`npm install gulp-cli -g`). If `gulp-cli` is not installed or an incompatible version is present, Gulp commands will not function correctly.","severity":"gotcha","affected_versions":">=1.0.0-alpha.0"},{"fix":"Use a Node.js version manager (like `nvm`) to switch to a compatible Node.js environment (e.g., Node.js 16 or 17) if encountering issues with newer Node.js runtimes.","message":"The package specifies older Node.js engine compatibility (`^17 || ^16 || ^15.0.1 || ^14 || ^12`). It may not function correctly with newer Node.js versions (e.g., Node.js 18+ or 20+), potentially leading to unexpected errors or installation issues.","severity":"gotcha","affected_versions":">=1.0.0-alpha.0"}],"env_vars":null,"last_verified":"2026-04-21T00:00:00.000Z","next_check":"2026-07-20T00:00:00.000Z","problems":[{"fix":"Ensure `gulpfile.js` and `gulpfile-config.json` exist in the root of your project directory. Navigate to the correct project directory before running `gulp` commands.","cause":"The `gulpfile.js` or `gulpfile-config.json` file is missing from the project root, or `gulp` is being run from the wrong directory.","error":"Error: Gulpfile not found"},{"fix":"Install `gulp` locally in your project: `npm install gulp@^4.0.0 --save-dev`. Verify that `gulpfile-config` is correctly requiring and using the `gulp` instance.","cause":"This error typically occurs if `gulp` (the package itself, not just `gulp-cli`) is not installed in your project, or if there's a version mismatch between `gulpfile-config`'s expectations and the installed `gulp` version.","error":"TypeError: gulp is not a function"},{"fix":"Install the package: `npm install gulpfile-config --save-dev`.","cause":"The `gulpfile-config` package has not been installed as a dependency in your project.","error":"Cannot find module 'gulpfile-config'"}],"ecosystem":"npm"}