-
-
Notifications
You must be signed in to change notification settings - Fork 38
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
[Feature request] Grep style directory exclusion #8
Comments
So the
I think the first two are fine, but the last one is totally unreasonable. I think the right approach would be:
which would prune anything named Another thing that's nicer with the
Much more compact with the brace-expansion.
|
Actually |
Oh damn, |
@bag-man The https://github.com/tavianator/bfs/tree/exclude branch implements this syntax:
What do you think? |
@tavianator Nice one, although I noticed that this worked:
But this didn't:
Which is a little confusing. |
Throwing another idea here: I’ve recently started using ag (the silver searcher), a grep replacement that looks for a .gitignore file for patterns to ignore. There is also a command-line option to add ignores. ag replaces a bunch of grep aliases that I was using to look for things in codebases; I don’t have to think about excluding |
I've been using bfs for a while now, it is excellent. One thing that find is terrible for is excluding directories, and I thought maybe bfs could add on a more use friendly system.
It would be a lot nicer if there was the option to exclude/include directories/files in the same way that grep does:
I'd be quite interested in helping to write this functionality, but I thought I would raise it as an issue first to see what your thoughts on it are.
The text was updated successfully, but these errors were encountered: