GLOV.js Build System is a specialized build tool designed for JavaScript game development, emphasizing fast, incremental builds and live updates for assets across various formats. Currently at version 1.0.53, it is no longer under active development but maintains MEDIUM-HIGH API stability, being used in multiple production projects. Its primary differentiator lies in its tailored approach to handle the unique demands and scaling challenges of large game projects built within the GLOV.js ecosystem, aiming to overcome shortcomings found in more general-purpose build systems when applied to this specific context. It orchestrates builds through a system of 'tasks' and 'jobs', where individual jobs are executed incrementally only if their dependencies have changed, and their outputs trigger further tasks only if the output truly differs, ensuring efficient processing by only rebuilding what is strictly necessary.
npm install glov-buildVerified import paths — ran on the pinned version, not inferred.
This example demonstrates how to configure `glov-build`, define two basic tasks ('copy' for single files and 'concat' for multiple files), establish dependencies, and run a default build with file watching.
Consider its 'maintenance' status when planning long-term project dependencies; be prepared to contribute or fork for specific needs.
Evaluate its suitability for your project's specific needs, especially if not within the GLOV.js or game development sphere. Refer to the GLOV.js build scripts for complex real-world usage examples.
Always use `const gb = require('glov-build');` to import the module. If integrating into an ESM-only project, consider a CommonJS wrapper or a dedicated build step for transpilation.Carefully select `gb.SINGLE` or `gb.ALL` based on whether your job needs to process files individually or collectively. Ensure your `func` implementation correctly handles the input format (`job.getFile()` vs `job.getFiles()`) for the chosen type.
Run `npm install glov-build` or `yarn add glov-build` in your project directory. Ensure the `require()` path is correct.
Verify that `const gb = require('glov-build');` was executed successfully and `gb` holds the module export. `task` is a method of the main `gb` object, not a standalone function or named export.Ensure `job.out()` receives an object with at least `relative` and `contents` (or a `File` object from `job.getFile()`). Always call `done()` at the end of your job function to signal completion, even if an error occurs.
Review the `input` glob pattern for syntax errors. Ensure the paths are relative to the configured `source` directory or absolute if specified.
No dependency data recorded yet.