correct regular expression

This commit is contained in:
Phred
2010-10-03 09:26:28 -07:00
parent bf32325fb3
commit c7cdd7c4af

View File

@@ -78,7 +78,9 @@ require('path').exists(ignoreFilePath, function () {
}
});
ignoreFileTime = stat.mtime;
reIgnoreFiles = new RegExp(ignoreFiles.join('|'))
reIgnoreFiles = new RegExp(ignoreFiles.map(function(file) {
return file.replace(/\./g, '\\.').replace(/\*/g, '.*');
}).join('|'));
}
});