Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode search by file or class name

Tags:

I would like to search for all .xib files in a particular xcode project but I don't know how to do this on xcode. Also, suppose I want to search for a particular file, e.g. Test.h, how do I do this? I know how to do this using linux, but that gives the structure of the filesystem, and not of the xcode project.

like image 576
OckhamsRazor Avatar asked Sep 07 '11 10:09

OckhamsRazor


People also ask

How do I search for a file in Xcode?

Quick Open 👉 ⇧⌘O You can use the text box to search by filename, method name, class name, etc. Just hit ↩ on the desired result to open its respective file on current active editor.

How do you do find and replace in Xcode?

Xcode displays the results of the search, but it doesn't automatically replace the text. To replace the text for a single result, select it and click the Replace button. To replace the text for all results, click Replace All.

How do I rename a file in Xcode?

Select the project you want to rename in the “Project Navigator” which can be found on the left side of the Xcode view. On the right-hand side of the window, select the “File Inspector”. The name of your project should be in there under “Identity and Type”, change it to “NEW” and press Enter.


1 Answers

In xcode on left pane at the bottom there is a search field, just type xib, it should list all xib files. Same with other type of searches as well.

Place your cursor in this "Filter" with a keyboard shortcut: + + J , or by choosing from the File Menu Edit > Filter > Filter in Navigator

like this

Edit:

You can even use wildcards. For e.g., *m*1.x* will filter SampleXib1.xib, It's also incase-sensitive.

like image 162
Saran Avatar answered Sep 17 '22 15:09

Saran