I'm trying to search through the files and directories of a specific folder. For example, I was looking in /usr/bin
for my python
binaries. To do so, I used ls | grep python
. When I did this, I was able to find, for example, python3
, python3-config
, etc.
While this works fine, I know that there are easier ways to do that: I shouldn't have to pipe to grep
. But when I tried find . -name python
, as per my understanding of the find
man page, it yielded no results.
I know that grep
searches through a file. What is the correct way to search through a given directory?