1.0.4 • Published 8 years ago

gulp-luacheck v1.0.4

Weekly downloads
1
License
MIT
Repository
github
Last release
8 years ago

gulp-luacheck

A Gulp plugin for luacheck.

Dependencies

You must have luacheck installed and in your PATH.

Installation

npm install gulp-luacheck

Usage

var gulp = require("gulp");
var luacheck = require("gulp-luacheck");
var options = {};


gulp.task("lint", function() {
    return gulp
        .src("**/*.lua")
        .pipe(luacheck(options))
        .pipe(luacheck.reporter())
});

For a list of options, see node-luacheck

Reporters

A jshint-stylish-like reporter is also bundled:

    gulp.src("**/*.lua")
        .pipe(luacheck())
        .pipe(luacheck.reporter("stylish"))

By default errors are not fatal (so as to not break the stream when using gulp.watch). If you want gulp to crash when there's a linting error (for example if you're using gulp as part of CI), you'll want to use the fail reporter (also bundled):

    gulp.src("**/*.lua")
        .pipe(luacheck())
        .pipe(luacheck.reporter())
        .pipe(luacheck.reporter("fail"))

License

gulp-luacheck is licensed under the MIT license.