Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am not able to figure out how can I do case-insensitive search using the find command.

I tried

find . -name -i pattern

And it does not work.

share|improve this question

migrated from stackoverflow.com Apr 29 '11 at 22:58

This question came from our site for professional and enthusiast programmers.

add comment

3 Answers

Use this:

find . -iname PatTeRn -print
share|improve this answer
add comment

I believe it's: find . -iname pattern

From man find:

-iname pattern
       Like  -name, but the match is case insensitive.
share|improve this answer
add comment
sudo updatedb

locate -i "nameofthefile"

nameofthefile should be without the inverted commas.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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