2016-10-10 03:43:44 +02:00
|
|
|
# gulp-debug [![Build Status](https://travis-ci.org/sindresorhus/gulp-debug.svg?branch=master)](https://travis-ci.org/sindresorhus/gulp-debug)
|
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
> Debug [Vinyl](https://github.com/gulpjs/vinyl) file streams to see what files are run through your Gulp pipeline
|
2016-10-10 03:43:44 +02:00
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
<img src="screenshot.png" width="415">
|
2016-10-10 03:43:44 +02:00
|
|
|
|
|
|
|
|
|
|
|
## Install
|
|
|
|
|
|
|
|
```
|
|
|
|
$ npm install --save-dev gulp-debug
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
## Usage
|
|
|
|
|
|
|
|
```js
|
2017-08-14 05:01:11 +02:00
|
|
|
const gulp = require('gulp');
|
|
|
|
const debug = require('gulp-debug');
|
2016-10-10 03:43:44 +02:00
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
gulp.task('default', () =>
|
|
|
|
gulp.src('foo.js')
|
2016-10-10 03:43:44 +02:00
|
|
|
.pipe(debug({title: 'unicorn:'}))
|
2017-08-14 05:01:11 +02:00
|
|
|
.pipe(gulp.dest('dist'))
|
|
|
|
);
|
2016-10-10 03:43:44 +02:00
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
## API
|
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
### debug([options])
|
2016-10-10 03:43:44 +02:00
|
|
|
|
|
|
|
#### options
|
|
|
|
|
|
|
|
##### title
|
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
Type: `string`<br>
|
|
|
|
Default: `gulp-debug:`
|
2016-10-10 03:43:44 +02:00
|
|
|
|
|
|
|
Give it a custom title so it's possible to distinguish the output of multiple instances logging at once.
|
|
|
|
|
|
|
|
##### minimal
|
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
Type: `boolean`<br>
|
2016-10-10 03:43:44 +02:00
|
|
|
Default: `true`
|
|
|
|
|
|
|
|
By default only relative paths are shown. Turn off minimal mode to also show `cwd`, `base`, `path`.
|
|
|
|
|
|
|
|
The [`stat` property](http://nodejs.org/api/fs.html#fs_class_fs_stats) will be shown when you run gulp in verbose mode: `gulp --verbose`.
|
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
##### showFiles
|
|
|
|
|
|
|
|
Type: `boolean`<br>
|
|
|
|
Default: `true`
|
|
|
|
|
|
|
|
Setting this to false will skip printing the file names and only show the file count.
|
|
|
|
|
2016-10-10 03:43:44 +02:00
|
|
|
|
|
|
|
## License
|
|
|
|
|
2017-08-14 05:01:11 +02:00
|
|
|
MIT © [Sindre Sorhus](https://sindresorhus.com)
|