4

Is there a way to search files with netrw similar to find command in linux?

So in command line I can do

find . -name "pattern"

Is there something similar in netrw?

2
  • In netrw? Not to my knowledge. In Vim? Yes of course, there are many ways to find files, including that very same command. But find . -name "pattern" on its own would be just as pointless in Vim as in your shell. You want to find files, OK, but what do you want to do with the result?
    – romainl
    Aug 28, 2015 at 8:20
  • 1
    One nice way would be to :.!find . -type f -name "patern" in an empty buffer and then use gf on each entry.
    – Vitor
    Aug 28, 2015 at 17:34

2 Answers 2

3

You have plugins to do so :

Or you can do by hand :

With a unix command from vim :

:!find . -name "pattern"

With the Explore command :

:Explore pattern

Based on this post this function is available through the netrw.vim file.

2
1

Yes -- seems you have a number of people answering who don't use gvim because such search support is easily seen under the netrw menu. So, look at :help netrw-star . In particular, :Explore */pattern .

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.