Text search though all .xib files in Xcode?

Solution 1:

What I do is run grep in terminal:

grep -i -r --include=*.xib "TextToFindHere" /PathToSearchHere

Xcode doesn't seem to have an option to search xib files and my attempts to get Spotlight to look at them have been unsuccessful.

Solution 2:

Here is my handy command that never fails me. Run it from the project directory in Terminal.

find . -name "*.xib" -exec grep "text to look for" {} \; -print

Solution 3:

I realize this is quite old, but I'd like to suggest to those of you who happen to also code other languages on your computer and choose to use Sublime Text 2 (which is wonderful) to do so, just open your iOS project's folder in Sublime and use the find all feature. Very fast, very reliable.

This was what I did to remove unused image resources from one of my larger projects.

~ Happy Coding =]

Solution 4:

I may be daft, but using spotlight works great for me on this one.