How do you duplicate a file in XCode?

Solution 1:

In XCode 4.2 (I know this is an old question) there is Duplicate under the File menu.

Select the file (you can select multiple files but it doesn't appear to do anything useful) in the Project Navigator and then File->Duplicate. Hooray!

Solution 2:

In Xcode 4.5 we can duplicate using File-> Duplicate or cmd + shift + S

Solution 3:

"Duplicate" is enabled for targets in XCode (pretty much nothing else that I know of).

If you have a substantial number of subclasses with the same starting point to replicate, why not make a class template from it? Then you can just use file->New to make new instances. It's fairly quick to do.

This is probably the simplest example:

http://www.macresearch.org/custom_xcode_templates

Otherwise, I'd simply duplicate the files in Finder as many times as you need, name them, and drag them into XCode en-masse.