0.3.0 • Published 7 years ago

gulp-indent-checker v0.3.0

Weekly downloads
31
License
MIT
Repository
-
Last release
7 years ago

Build Status Coverage Status Dependency Status Code Quality

gulp-indent-checker

Gulp plugin to validate that all files follow indent styling.

Version

This documentation refers to gulp-indent-checker verions 0.1.0

Synopsis

var gulp = require('gulp'),
  indents = require('gulp-indent-checker');

gulp.task('check-indentation', function () {
  return gulp.src('src/**')
    .pipe(indents({
      warn: false,
      throwAtEnd: false,
      type: false
    }));
});

Description

gulp-indent-checker aims to help enforce indentation style in a project. This is particularly useful for file types that don't have a lint plugin.

Options

There are three options to effect how gulp-indent-checker works:

  • type - Specifies the type of indentation allowed
    • 'tabs' - allow only tabs for indentation
    • 'spaces' - allow only spaces for indentation
    • not set or false - allow only one type of indentation in a file (errors if indentation is mixed tabs and spaces)
  • warn - Warn about files that don't meet indentation style
  • throwAtEnd - Only throw an error after all files are processed.