Pages

Friday, May 14, 2010

Xcode. Smart Groups

I'm not a very experienced Xcode user, so only today I found out that there is a nice feature - a possibility to group project files with the smart groups. By default any Xcode project has two smart groups: "Implementation Files" and "Interface Builder Files". Their folder icons are colored purple:
The smart groups filter the file names based on a set of rules. For example the Implementation Files smart group displays only the files with extensions c, cpp, m,.. - the implementation files. This rule is specified using the regular expression - a small sophisticated language for recognizing the patterns within the strings. If this Implementation Files group is selected (as it is shown on the screenshot above), click on the right mouse button will show the popup menu "Get Info" will show the pattern:
It is possible to own smart groups - in the Project menu choose New Smart Group.
I my test project I created two Smart Groups. The second group (shown on the screenshot below) show the files that have "math" in their names:


More info in the Mac OS X Reference Library: Project Organization

No comments:

Post a Comment