-
Notifications
You must be signed in to change notification settings - Fork 91
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how to ignore node_modules using the cli API? #329
Comments
something like this: esformatter '!(node_modules|build|dist){,/**/}*.js' (rough!) |
@millermedeiros this is not the best option since it emits an error when you do not have any subdirectory.. Maybe you have a better idea? |
So that's because when you give a pattern to glob that results in no matches, you get back a similar pattern. Switching to non sync glob should solve the issue, but that's some work |
yes, we need a better way to do this and also to add it to the docs. the error I did on purpose because I assumed it was better to display that it couldn't find any files with the glob than to fail silently.. (specially for cases like |
I think we should probably add an esformatter --ignore-dir=node_modules --ignore-dir=build --ignore-dir=dist './**/*.js' and maybe ignore |
sorry for the huuuuuuge delay, but in the next version (v0.10.0) we will be able to specify complex ignore rules like: esformatter --diff --ignore 'node_modules/**' --ignore 'test/compare/**/*-in.js' --ignore 'test/compare/{jquery,custom,rc,error}/**/*.js' '**/*.js' I'll probably do some follow up work on #449 to support |
Let's say I want to rewrite all the JavaScript files in my project BUT the node_modules, how to do that?
The text was updated successfully, but these errors were encountered: