Socket
Socket
Sign inDemoInstall

gulp-task-loader-recursive

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-task-loader-recursive - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

4

index.js

@@ -31,2 +31,6 @@ var fs = require('fs');

if (typeof task !== 'function') {
task = function () {};
}
if (typeof task.dependencies === 'object') {

@@ -33,0 +37,0 @@ gulp.task(taskName, task.dependencies, task);

2

package.json
{
"name": "gulp-task-loader-recursive",
"version": "1.0.0",
"version": "1.0.1",
"description": "Easily organize gulp tasks in separate files and folders",

@@ -5,0 +5,0 @@ "main": "index.js",

# gulp-task-loader-recursive
Easily organize gulp tasks in separate files and folders
## Install
```npm install --save-dev gulp-task-loader-recursive```
## Files structure
You can create files and directories under ```tasks/``` folder. For example:
```
|-- gulpfile.js
|-- tasks/
|-- build/
|-- css.js
|-- js.js
|-- watch/
|-- public.js
|-- build.js
|-- default.js
|-- serve.js
```
And as a result you'll have following tasks:
```
build:css
build:js
watch:public
build
default
serve
```
You can define tasks as follows:
```
var gulp = require('gulp');
module.exports = function () {
gulp.src('./src')
.pipe(gulp.dest('./dst'))
;
};
```
Also you can provide tasks dependencies:
```
module.exports.dependencies = [ 'build:css' ];
```
## Usage
To be able to use this tasks you need to add the following to your gulpfile.js:
```
require('gulp-task-loader-recursive')();
```
If you want to use other tasks directory, just pass it as a parameter:
```
require('gulp-task-loader-recursive')('./gulp-tasks');
```
You can also provide prefix for all tasks loaded by this method:
```
require('gulp-task-loader-recursive')(null, 'custom:tasks:prefix');
```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc