gulp-dest
Gulp plugin for easily defining destination paths using path variables.
Install with npm
$ npm i gulp-dest --save
Example
var dest = ;var gulp = ; gulp; //=> ['dist/a.html', 'dist/b.html', 'dist/c.html']
Usage
; // example;
- directory
{String}
: Optionally define a path to be append to the path (file.base
) specified ingulp.dest()
- options
{Object}
: Pass file path properties to use. Supported properties areext
orextname
,dirname
andbasename
(although I'm not sure why you would use it)
Path variables
Dynamically replace variables with actual path values:
Examples
// Given: ['a.coffee', 'b.coffee', 'c.min.coffee'];//=> ['a.js', 'b.js', 'c.min.js'] // Given: ['foo/a.coffee', 'bar/b.coffee', 'baz/c.coffee'];//=> ['qux/a.js', 'qux/b.js', 'qux/c.js']
Any properties defined on the options can be used as path variables:
Example
var dest = ;var gulp = ; gulp; //=> ['bar/a.js', 'bar/b.js', 'bar/c.js']
Related projects
- gulp-assemble: Gulp plugin for Assemble. | homepage
- gulp-drafts: Gulp plugin for removing files flagged as drafts. Can also be used as an assemble… more | homepage
- gulp-extname: gulp plugin to dynamically rewrite dest extensions based on src extensions. | homepage
- gulp-routes: Add middleware to run for specified routes in your gulp pipeline. | homepage
Running tests
Install dev dependencies:
$ npm i -d && npm test
Contributing
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Author
Jon Schlinkert
License
Copyright © 2015 Jon Schlinkert Released under the MIT license.
This file was generated by verb-cli on October 27, 2015.