Version 1.0.0
@stackline/load-grunt-tasks
Load multiple grunt tasks using globbing patterns
Independent maintenance of load-grunt-tasks 5.1.0. Original authors and licenses are retained.
Installation
# Preserve existing imports with an npm alias
npm install load-grunt-tasks@npm:@stackline/load-grunt-tasks@1.0.0
# Or use the scoped package name in your imports
npm install @stackline/load-grunt-tasks@1.0.0Node.js: >=8. Read the compatibility and maintenance notes before migrating.
Usage and API
The reference below may retain upstream package names. Use the alias installation above to run those imports with this Stackline release.
@stackline/load-grunt-tasks
Independent maintenance fork of load-grunt-tasks@5.1.0. Original API, module format, runtime dependency ranges, and supported Node.js engines are preserved.
npm install @stackline/load-grunt-tasks
# Preserve existing imports with an npm alias:
npm install load-grunt-tasks@npm:@stackline/load-grunt-tasks@1.0.0
See UPSTREAM.md for the exact source and issue review, and CHANGELOG.md for focused maintenance changes. Development and release tooling runs on Node.js 24; that does not change the library runtime requirement.
Maintained by Stackline. Issues · npm.
Upstream documentation
load-grunt-tasks 
Load multiple grunt tasks using globbing patterns
Usually you would have to load each task one by one, which is unnecessarily cumbersome.
This module will read the dependencies/devDependencies/peerDependencies/optionalDependencies in your package.json and load grunt tasks that match the provided patterns.
Before
grunt.loadNpmTasks('grunt-shell');
grunt.loadNpmTasks('grunt-sass');
grunt.loadNpmTasks('grunt-recess');
grunt.loadNpmTasks('grunt-sizediff');
grunt.loadNpmTasks('grunt-svgmin');
grunt.loadNpmTasks('grunt-styl');
grunt.loadNpmTasks('grunt-php');
grunt.loadNpmTasks('grunt-eslint');
grunt.loadNpmTasks('grunt-concurrent');
grunt.loadNpmTasks('grunt-bower-requirejs');
After
require('load-grunt-tasks')(grunt);
Install
$ npm install --save-dev load-grunt-tasks
Usage
// Gruntfile.js
module.exports = grunt => {
// Load all grunt tasks matching the ['grunt-*', '@*/grunt-*'] patterns
require('load-grunt-tasks')(grunt);
grunt.initConfig({});
grunt.registerTask('default', []);
};
Examples
Load all grunt tasks
require('load-grunt-tasks')(grunt);
Equivalent to:
require('load-grunt-tasks')(grunt, {pattern: ['grunt-*', '@*/grunt-*']});
Load all grunt-contrib tasks
require('load-grunt-tasks')(grunt, {pattern: 'grunt-contrib-*'});
Load all grunt-contrib tasks and another non-contrib task
require('load-grunt-tasks')(grunt, {pattern: ['grunt-contrib-*', 'grunt-shell']});
Load all grunt-contrib tasks excluding one
You can exclude tasks using the negate ! globbing pattern:
require('load-grunt-tasks')(grunt, {pattern: ['grunt-contrib-*', '!grunt-contrib-coffee']});
Set custom path to package.json
require('load-grunt-tasks')(grunt, {config: '../package'});
Only load from devDependencies
require('load-grunt-tasks')(grunt, {scope: 'devDependencies'});
Only load from devDependencies and dependencies
require('load-grunt-tasks')(grunt, {scope: ['devDependencies', 'dependencies']});
All options in use
require('load-grunt-tasks')(grunt, {
pattern: 'grunt-contrib-*',
config: '../package.json',
scope: 'devDependencies',
requireResolution: true
});
Options
pattern
Type: string | string[]
Default: ['grunt-*', '@*/grunt-*'] (Glob pattern)
config
Type: string | object
Default: Path to nearest package.json
scope
Type: string | string[]
Default: ['dependencies', 'devDependencies', 'peerDependencies', 'optionalDependencies']
Values: 'dependencies', 'devDependencies', 'peerDependencies', 'optionalDependencies', 'bundledDependencies'
requireResolution
Type: boolean
Default: false
Traverse up the file hierarchy looking for dependencies like require(), rather than the default grunt-like behavior of loading tasks only in the immediate node_modules directory.
Upstream issues and maintenance review
Upstream review
Based on load-grunt-tasks@5.1.0, commit fddcf81829b1e88f3daf855ea2aa759224dec98a. All published upstream runtime files match this commit byte-for-byte; npm tarball integrity was independently checked.
The fork preserves runtime files, exports, CLI names and engine declarations. Original license and authorship notices remain. Development tooling runs on Node24 without raising the package runtime requirement.
Issue triage (2026-09-29)
The upstream open-issue snapshot returned no open issues. This is not a claim that every historical issue has been solved. Added real task discovery, scoped filtering, exclusion and package-resolution checks in addition to the upstream Grunt smoke test.
No upstream maintainers were contacted. These are scoped compatibility decisions, not blanket claims that upstream issues are fixed.
Verification
npm ci --ignore-scripts, npm test, npm run test:package, and npm audit --audit-level=low. CI and CodeQL gate the exact immutable package artifact. Packed consumer tests install the resulting archive before exercising its public behavior.
Release changes
Stackline changes
1.0.0
- Independent scoped maintenance release based on the exact upstream source listed in UPSTREAM.md. Runtime source, CLI names, license, API and engine declarations are preserved.
- Replaced obsolete development-only release, coverage and lint tooling with supported test dependencies. Retained functional upstream suites and added packed-consumer contract checks.
- Added audited reproducible CI, CodeQL, artifact-only npm publication with provenance, and immutable GitHub release evidence.
Release files and references
Package bytes, npm provenance and the immutable GitHub release were verified for this version. Security checks describe the reviewed release; documented compatibility risks and upstream reports are not blanket claims of resolution.