Skip to content
/ gulp-wc Public

gulp plugin to just count lines of code passed from stream.

License

Notifications You must be signed in to change notification settings

t5kaji/gulp-wc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 

Repository files navigation

gulp-wc

A gulp plugin to just count lines of code passed from stream.

Usage

First of all, install the gulp-wc plugin:

npm install gulp-wc

Furthurmore, add the plugin to your gulpfile.js:

var wc = require('gulp-wc');

gulp.task('wc', function() {
	return gulp.src(['js/*.js', 'js2/*.js', 'js3/*.js','js4/*.js','js5/*.js','css/*.css'])
        .pipe(wc())
});

This would show the output like below:

-------------gulp-wc output start-------------
js/all.js :58 lines
js/test.js :29 lines
js2/all.js :58 lines
js2/test.js :29 lines
js3/all.js :58 lines
js3/test.js :29 lines
js4/all.js :58 lines
js4/test.js :29 lines
js5/all.js :58 lines
js5/test.js :29 lines
css/all.css :10 lines
css/test.css :9 lines
Total :454 lines

The output related to different parent directory, like "js" or "js2" in the example above, would be displayed with different color.

You can put this plugin's function in the middle of pipe chaining to see how many lines of code each file has before being processed.

About

gulp plugin to just count lines of code passed from stream.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published