Allow for excluding files/folders
jaredmcateer opened this issue · 3 comments
I'm trying to run this task with the following config:
grunt.initConfig({
htmllint: {
all: ["**/*.html", "!coverage/**/*.html"]
}
});
I want all the html files to be tested except those in the code coverage directory but when I tried the standard !
prefix this I get the following error:
Error: Command failed: /bin/sh: 1: Syntax error: "(" unexpected
Seems like the exclusion pattern is passed through to the jar file, instead of getting replaced by grunt.file.expand
.
@jawshooah could you take a look?
I can't reproduce with an identical config. @jaredmcateer, do any of your HTML files have a '('
somewhere in their paths, by chance?
Looks like the file paths aren't quoted before being passed to vnu.jar
, so spaces or special characters in the path break everything. Submitting a PR that should fix it.