gulp-tinstall

0.4.0 • Public • Published

gulp-install NPM version Build Status Dependency Status

Automatically install npm and bower packages if package.json or bower.json is found in the gulp file stream respectively

Primary objective

Used as the install step when using slush as a Yeoman replacement.

Installation

For global use with slush

Install gulp-install as a dependency:

npm install --save gulp-install

For local use with gulp

Install gulp-install as a development dependency:

npm install --save-dev gulp-install

Usage

In your slushfile.js:

var install = require("gulp-install");
 
gulp.src(__dirname + '/templates/**')
  .pipe(gulp.dest('./'))
  .pipe(install());

In your gulpfile.js:

var install = require("gulp-install");
 
gulp.src(['./bower.json', './package.json'])
  .pipe(install());

Options

To not trigger the install use --skip-install as CLI parameter when running slush or gulp.

options.production

Type: Boolean

Default: false

Set to true if npm install should be appended with the --production parameter when stream contains package.json.

Example:

var install = require("gulp-install");
 
gulp.src(__dirname + '/templates/**')
  .pipe(gulp.dest('./'))
  .pipe(install({production: true}));  

options.ignoreScripts

Type: Boolean

Default: false

Set to true if npm install should be appended with the --ignore-scripts parameter when stream contains package.json. Useful for skipping postinstall scripts with npm.

Example:

var install = require("gulp-install");
 
gulp.src(__dirname + '/templates/**')
  .pipe(gulp.dest('./'))
  .pipe(install({ignoreScripts: true}));

License

MIT License

Package Sidebar

Install

npm i gulp-tinstall

Weekly Downloads

1

Version

0.4.0

License

MIT

Last publish

Collaborators

  • ywqsimmon