charlierudolph / dependency-lint

Lints NPM dependencies and devDependencies
MIT License
14 stars 6 forks source link

Cucumber snippets listed in cucumber.js should be ignored #27

Open kevgo opened 8 years ago

kevgo commented 8 years ago

I am using https://github.com/kevgo/cucumber-snippets-livescript to provide Cucumber snippets in Livescript. Those show up as false positive unused modules. I think a simple match for:

--snippet-syntax node_modules/XXX"

should add XXX to the list of automatically ignored modules.

charlierudolph commented 8 years ago

Hmm. Thats a tough case. I'm not certain how to deal with that generically. I guess we could search for node_modules/* or ./node_modules/* in the npm scripts and shell scripts. What do you think of that?

kevgo commented 8 years ago

Maybe a super-generic executedModules/other category, which just does a regex search for \b node_modules/(.*)\b in the files listed there?

charlierudolph commented 8 years ago

I don't think this belongs under executedModules but maybe something new called referencedModules which can either do a search for node_modules/<name> or just <name> in some configured files

kevgo commented 8 years ago

Yes, referencedModules sounds like the right place for this.