Skip to content
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

Support !directory to exclude a dir from consideration? #871

Closed
mqudsi opened this issue Mar 29, 2018 · 4 comments
Closed

Support !directory to exclude a dir from consideration? #871

mqudsi opened this issue Mar 29, 2018 · 4 comments
Labels
question An issue that is lacking clarity on one or more points.

Comments

@mqudsi
Copy link

mqudsi commented Mar 29, 2018

@BurntSushi Would you be open to having rg PATTERN !DIR [!DIR2 ..] be used to exclude a directory from consideration at the command line?

@BurntSushi
Copy link
Owner

No. I've never seen another tool do this, and I would prefer not to continue the spread of the use of ! in command line arguments.

@BurntSushi BurntSushi added the question An issue that is lacking clarity on one or more points. label Mar 29, 2018
@mqudsi
Copy link
Author

mqudsi commented Mar 29, 2018

Thanks for the quick reply. What about an option to exclude a path, then (without -g !) (a la many tools' -x PATH option)?

@BurntSushi
Copy link
Owner

@mqudsi Well, yes, I never would have used ! if it were simple to add a -G (negation of -g) flag. :-) That work is tracked in #809, and I believe it's now possible to implement given improvements in the latest release of clap (argv parser). I'll probably get around to it in the next release.

@mqudsi
Copy link
Author

mqudsi commented Mar 29, 2018

Thanks :)

@mqudsi mqudsi closed this as completed Mar 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question An issue that is lacking clarity on one or more points.
Projects
None yet
Development

No branches or pull requests

2 participants