function lint() {
	var pattern;
	var options;
	var clbk;
	var opts;
	var dir;
	var err;

	opts = copy( DEFAULTS );
	if ( arguments.length < 2 ) {
		clbk = arguments[ 0 ];
	} else {
		options = arguments[ 0 ];
		clbk = arguments[ 1 ];
		err = validate( opts, options );
		if ( err ) {
			throw err;
		}
	}
	if ( !isFunction( clbk ) ) {
		throw new TypeError( format( 'invalid argument. Callback argument must be a function. Value: `%s`.', clbk ) );
	}
	if ( opts.dir ) {
		dir = resolve( cwd(), opts.dir );
	} else {
		dir = cwd();
	}
	pattern = opts.pattern;

	opts = {
		'cwd': dir,
		'ignore': IGNORE,
		'nodir': true // do not match directories
	};
	glob( pattern, opts, onGlob );

	/**
	* Callback invoked after matching files.
	*
	* @private
	* @param {(Error|null)} error - error object
	* @param {(EmptyArray|StringArray)} names - list of matching files
	* @returns {void}
	*/
	function onGlob( error, names ) {
		if ( error ) {
			return clbk( error );
		}
		clbk( null, linter( names ) );
	}
}
Asynchronously lints filenames.

@param {Options} [options] - function options
@param {string} [options.dir] - root directory from which to search for files
@param {string} [options.pattern='**\/*'] - filename pattern
@param {Callback} clbk - callback to invoke after linting
@throws {TypeError} options argument must be an object
@throws {TypeError} must provide valid options
@throws {TypeError} must provide a function

@example
lint( onLint );

function onLint( error, errs ) {
    if ( error ) {
        throw error;
    }
    console.error( errs );
}