Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8538573
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T11:08:56+00:00 2026-06-11T11:08:56+00:00

I’m trying to add a custom code template into Xcode. Based on my reading,

  • 0

I’m trying to add a custom code template into Xcode. Based on my reading, this is the procedure I’ve come up with.

First, access the folder path

Application/Xcode45-DP3.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Templates/Project Templates/Application

Second, make a copy of one of the existing folders to use as a starting point.

Third, change that folder name to what I want.

The part that I’m having trouble with is that there are no files with the code that I want to modify, such as PROJECTNAME.xcodeproj, anyfilename.h, anyfilename.h, etc., there is only MainStoryBoard_iPad(and iPhone).storyboard, ViewcontrolleriPad(and iPhone).Xib, TemplateIcon.tiff and TemplateInfo.plist.

What’s the proper way to do this? What am I missing?

enter image description here

enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T11:08:57+00:00Added an answer on June 11, 2026 at 11:08 am

    What are you trying to create? A project Template or a File Template?

    • If you want to create a new File Template, you need to copy a whole "*.xctemplate" folder from "/Xcode/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Templates/File Templates" (that you will use as an example/starting point) to "~/Library/Application Support/Developer/Shared/Xcode/File Templates".
    • If you want to create a new Project Template, do the same with one "*.xctemplate" folder from "/Xcode/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Templates/Project Templates" to "~/Library/Application Support/Developer/Shared/Xcode/Project Templates"
    • If the "File Templates"/"Project Templates" folder is not present in App Support, create them.

    Don’t copy the template into the Xcode bundle itself as it is not intended to (and violates the sandbox concept, and will be overridden the next time you upgrade your Xcode version) but use the Application Support folder for that as it is its very purpose.

    Once you have copied one .xctemplate folder from the Xcode bundle to the corresponding App Support folder, you can modify the content of the .xctemplate to fit your needs.


    Now for the fact that you don’t have any xcodeproj in the xctemplate folder, this is because the project that is created by a Project Template is not defined using a xcodeproj file, but rather with keys in the TemplateInfo.plist file.

    For example, in "Project Templates/Mac/Mac Base.xctemplate/TemplateInfo.plist" you can see a key named "Project" with subkeys "Configurations", "SDK", and "SharedSettings" that defines some Build Settings for the xcodeproj to be created by the template.

    Moreover, be aware that templates have some kind of “inheritance” concept, each template being able to have “ancestors” that define common keys:

    • Open the "TemplateInfo.plist" file and look at the "ancestors" key
    • You will find here an array of identifiers for the ancestors of the selected template. For example, the "Cocoa Application.xctemplate" template have "com.apple.dt.unit.cocoaApplicationBase" as one of its ancestor.
    • Then go and find the template whose identifier is the one found in the ancestor key (in my example, it is the "Cocoa Application Base.xctemplate" template, as in its TemplateInfo.plist you can see that its "Identifier" key is the "com.apple.dt.unit.cocoaApplicationBase" we saw above).

    And You can go up like that until the base template, having some kind of “inheritence” for the template definition.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I have this code to decode numeric html entities to the UTF8 equivalent character.
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has
For some reason, after submitting a string like this Jack’s Spindle from a text

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.