{"id":2082,"date":"2020-06-14T20:00:00","date_gmt":"2020-06-14T18:00:00","guid":{"rendered":"http:\/\/www.albertopasca.it\/whiletrue\/?p=2082"},"modified":"2023-06-26T15:52:35","modified_gmt":"2023-06-26T13:52:35","slug":"create-your-own-xcode-template","status":"publish","type":"post","link":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/","title":{"rendered":"Create your own XCode template"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Very often you create a <em>new class<\/em> or a new <em>view controller<\/em> and customize it before start coding.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Every time you select from <strong>XCode<\/strong>, <strong>New File<\/strong>, the file type and add it to your project, <em>like this<\/em>:<\/p>\n\n\n\n<!--more-->\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1490\" height=\"1072\" src=\"https:\/\/i2.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-15.59.15.png?fit=525%2C378&amp;ssl=1\" alt=\"\" class=\"wp-image-2086\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-15.59.15.png?w=1490&amp;ssl=1 1490w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-15.59.15.png?resize=300%2C216&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-15.59.15.png?resize=1024%2C737&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-15.59.15.png?resize=768%2C553&amp;ssl=1 768w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n<\/div>\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-red-color has-css-opacity has-vivid-red-background-color has-background\"\/>\n\n\n\n<p class=\"wp-block-paragraph\">Why you do not create a custom file template with customized options based on your exigence?<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Like this:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1528\" height=\"1124\" src=\"https:\/\/i1.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=525%2C386&amp;ssl=1\" alt=\"\" class=\"wp-image-2092\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?w=1528&amp;ssl=1 1528w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?resize=300%2C221&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?resize=1024%2C753&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?resize=768%2C565&amp;ssl=1 768w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n<\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1518\" height=\"1112\" src=\"https:\/\/i1.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.52.png?fit=525%2C385&amp;ssl=1\" alt=\"\" class=\"wp-image-2093\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.52.png?w=1518&amp;ssl=1 1518w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.52.png?resize=300%2C220&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.52.png?resize=1024%2C750&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.52.png?resize=768%2C563&amp;ssl=1 768w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">This screenshot show you how to create a new file(s) with the type you prefer:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Class<\/li>\n\n\n\n<li>Codable Struct<\/li>\n\n\n\n<li>Enum<\/li>\n\n\n\n<li>Extension<\/li>\n\n\n\n<li>With Storyboard, with XIB or nothing<\/li>\n\n\n\n<li>etc..<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-cyan-blue-color has-css-opacity has-vivid-cyan-blue-background-color has-background\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">XCode original templates<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">If you want to take a look to the original XCode templates, that are installed in this folder:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">\/Applications\/Xcode.app\/Contents\/Developer\/Platforms\/\n  iPhoneOS.platform\/Developer\/Library\/Xcode\/Templates\n\nTemplates -&gt; File Templates\n          -&gt; Project Templates<\/pre>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-cyan-blue-color has-css-opacity has-vivid-cyan-blue-background-color has-background\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Creating a new template<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Start creating a new folder wherever you want (is not important for now). Call it &#8220;<strong>Custom Swift.xctemplate<\/strong>&#8220;.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">&#8220;<strong>Custom Swift<\/strong>&#8221; will be the name of the file in the source group of New File, in XCode.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Next step, copy one existing &#8220;<strong>TemplateInfo.plist<\/strong>&#8221; from another template in your folder and open it with <em>XCode<\/em> for editing (<em>or copy the following code and save as <strong>TemplateInfo.plist<\/strong>, suggested.<\/em>) <\/p>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-cyan-blue-color has-css-opacity has-vivid-cyan-blue-background-color has-background\"\/>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"xml\" class=\"language-xml\">&lt;?xml version=\"1.0\" encoding=\"UTF-8\"?&gt;\n&lt;!DOCTYPE plist PUBLIC \"-\/\/Apple\/\/DTD PLIST 1.0\/\/EN\" \"http:\/\/www.apple.com\/DTDs\/PropertyList-1.0.dtd\"&gt;\n&lt;plist version=\"1.0\"&gt;\n&lt;dict&gt;\n\t&lt;key&gt;DefaultCompletionName&lt;\/key&gt;\n\t&lt;string&gt;Custom Swift file&lt;\/string&gt;\n\t&lt;key&gt;Description&lt;\/key&gt;\n\t&lt;string&gt;This generates a new Swift file using custom format template.&lt;\/string&gt;\n\t&lt;key&gt;Kind&lt;\/key&gt;\n\t&lt;string&gt;Xcode.IDEKit.TextSubstitutionFileTemplateKind&lt;\/string&gt;\n\t&lt;key&gt;Options&lt;\/key&gt;\n\t&lt;array&gt;\n\t\t&lt;dict&gt;\n\t\t\t&lt;key&gt;Description&lt;\/key&gt;\n\t\t\t&lt;string&gt;The name of the module to create&lt;\/string&gt;\n\t\t\t&lt;key&gt;Default&lt;\/key&gt;\n\t\t\t&lt;string&gt;&lt;\/string&gt;\n\t\t\t&lt;key&gt;Identifier&lt;\/key&gt;\n\t\t\t&lt;string&gt;moduleName&lt;\/string&gt;\n\t\t\t&lt;key&gt;Name&lt;\/key&gt;\n\t\t\t&lt;string&gt;New Module Name:&lt;\/string&gt;\n\t\t\t&lt;key&gt;Required&lt;\/key&gt;\n\t\t\t&lt;string&gt;YES&lt;\/string&gt;\n\t\t\t&lt;key&gt;Type&lt;\/key&gt;\n\t\t\t&lt;string&gt;text&lt;\/string&gt;\n\t\t&lt;\/dict&gt;\n\t\t&lt;dict&gt;\n\t\t\t&lt;key&gt;Default&lt;\/key&gt;\n\t\t\t&lt;string&gt;___VARIABLE_moduleName___&lt;\/string&gt;\n\t\t\t&lt;key&gt;Identifier&lt;\/key&gt;\n\t\t\t&lt;string&gt;productName&lt;\/string&gt;\n\t\t\t&lt;key&gt;Type&lt;\/key&gt;\n\t\t\t&lt;string&gt;static&lt;\/string&gt;\n\t\t&lt;\/dict&gt;\n\t\t&lt;dict&gt;\n\t\t\t&lt;key&gt;Identifier&lt;\/key&gt;\n\t\t\t&lt;string&gt;interface&lt;\/string&gt;\n\t\t\t&lt;key&gt;Name&lt;\/key&gt;\n\t\t\t&lt;string&gt;Generate Interface Builder:&lt;\/string&gt;\n\t\t\t&lt;key&gt;Description&lt;\/key&gt;\n\t\t\t&lt;string&gt;Which interface builder to generate&lt;\/string&gt;\n\t\t\t&lt;key&gt;Type&lt;\/key&gt;\n\t\t\t&lt;string&gt;popup&lt;\/string&gt;\n\t\t\t&lt;key&gt;Default&lt;\/key&gt;\n\t\t\t&lt;string&gt;None&lt;\/string&gt;\n\t\t\t&lt;key&gt;Values&lt;\/key&gt;\n\t\t\t&lt;array&gt;\n\t\t\t\t&lt;string&gt;XIB&lt;\/string&gt;\n\t\t\t\t&lt;string&gt;None&lt;\/string&gt;\n\t\t\t\t&lt;string&gt;Storyboard&lt;\/string&gt;\n\t\t\t&lt;\/array&gt;\n\t\t&lt;\/dict&gt;\n\t\t&lt;dict&gt;\n\t\t\t&lt;key&gt;Identifier&lt;\/key&gt;\n\t\t\t&lt;string&gt;complex&lt;\/string&gt;\n\t\t\t&lt;key&gt;Name&lt;\/key&gt;\n\t\t\t&lt;string&gt;Module type&lt;\/string&gt;\n\t\t\t&lt;key&gt;Description&lt;\/key&gt;\n\t\t\t&lt;string&gt;Type of a module to generate&lt;\/string&gt;\n\t\t\t&lt;key&gt;Type&lt;\/key&gt;\n\t\t\t&lt;string&gt;popup&lt;\/string&gt;\n\t\t\t&lt;key&gt;Default&lt;\/key&gt;\n\t\t\t&lt;string&gt;Struct&lt;\/string&gt;\n\t\t\t&lt;key&gt;Values&lt;\/key&gt;\n\t\t\t&lt;array&gt;\n\t\t\t\t&lt;string&gt;Class&lt;\/string&gt;\n\t\t\t\t&lt;string&gt;Struct&lt;\/string&gt;\n\t\t\t\t&lt;string&gt;Enum&lt;\/string&gt;\n\t\t\t\t&lt;string&gt;Extension&lt;\/string&gt;\n\t\t\t&lt;\/array&gt;\n\t\t&lt;\/dict&gt;\n\t&lt;\/array&gt;\n\t&lt;key&gt;Platforms&lt;\/key&gt;\n\t&lt;array&gt;\n\t\t&lt;string&gt;com.apple.platform.iphoneos&lt;\/string&gt;\n\t&lt;\/array&gt;\n\t&lt;key&gt;SortOrder&lt;\/key&gt;\n\t&lt;string&gt;1&lt;\/string&gt;\n\t&lt;key&gt;Summary&lt;\/key&gt;\n\t&lt;string&gt;This generates a new Swift file using custom format template.&lt;\/string&gt;\n&lt;\/dict&gt;\n&lt;\/plist&gt;\n<\/code><\/pre>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1918\" height=\"1796\" src=\"https:\/\/i2.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.46.32.png?fit=525%2C492&amp;ssl=1\" alt=\"\" class=\"wp-image-2114\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.46.32.png?w=1918&amp;ssl=1 1918w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.46.32.png?resize=300%2C281&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.46.32.png?resize=1024%2C959&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.46.32.png?resize=768%2C719&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.46.32.png?resize=1536%2C1438&amp;ssl=1 1536w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><figcaption class=\"wp-element-caption\">TemplateInfo.plist opened with XCode property file<\/figcaption><\/figure>\n<\/div>\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-cyan-blue-color has-css-opacity has-vivid-cyan-blue-background-color has-background\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Template composition<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Step by step description of the template file and how it works:<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">HEADER<\/h4>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1740\" height=\"164\" src=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.47.57.png?fit=525%2C50&amp;ssl=1\" alt=\"\" class=\"wp-image-2119\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.47.57.png?w=1740&amp;ssl=1 1740w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.47.57.png?resize=300%2C28&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.47.57.png?resize=1024%2C97&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.47.57.png?resize=768%2C72&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.47.57.png?resize=1536%2C145&amp;ssl=1 1536w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">This information is shown in the source file. There is the name of the new file to create and the description.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">OPTION 1<\/h4>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1750\" height=\"302\" src=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.08.png?fit=525%2C91&amp;ssl=1\" alt=\"\" class=\"wp-image-2122\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.08.png?w=1750&amp;ssl=1 1750w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.08.png?resize=300%2C52&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.08.png?resize=1024%2C177&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.08.png?resize=768%2C133&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.08.png?resize=1536%2C265&amp;ssl=1 1536w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">In the &#8220;Option&#8221; section you can decide the customizable options for your template. This information are shown after selecting your template, in the &#8220;next step&#8221; screen.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Here you can set the textbox value and description, aka the name of your module and a custom variable &#8220;<strong>moduleIdentifier<\/strong>&#8221; to use later.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">OPTION 2<\/h4>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1762\" height=\"166\" src=\"https:\/\/i1.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.15.png?fit=525%2C49&amp;ssl=1\" alt=\"\" class=\"wp-image-2126\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.15.png?w=1762&amp;ssl=1 1762w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.15.png?resize=300%2C28&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.15.png?resize=1024%2C96&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.15.png?resize=768%2C72&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.15.png?resize=1536%2C145&amp;ssl=1 1536w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Here we can decide the moduleName to use and replace in all of your created files<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">OPTION 3<\/h4>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1770\" height=\"382\" src=\"https:\/\/i1.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.29.png?fit=525%2C113&amp;ssl=1\" alt=\"\" class=\"wp-image-2129\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.29.png?w=1770&amp;ssl=1 1770w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.29.png?resize=300%2C65&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.29.png?resize=1024%2C221&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.29.png?resize=768%2C166&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.29.png?resize=1536%2C331&amp;ssl=1 1536w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">This option is used to show a &#8220;Combo box&#8221; with some options to select. In this case, we want to create a new Swift file + a XIB or Storyboard or Nothing.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Same as <strong>Option 1<\/strong>, you can set also the description of the field.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">OPTION 4<\/h4>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1746\" height=\"410\" src=\"https:\/\/i1.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.38.png?fit=525%2C123&amp;ssl=1\" alt=\"\" class=\"wp-image-2136\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.38.png?w=1746&amp;ssl=1 1746w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.38.png?resize=300%2C70&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.38.png?resize=1024%2C240&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.38.png?resize=768%2C180&amp;ssl=1 768w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-19.48.38.png?resize=1536%2C361&amp;ssl=1 1536w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Same as before, a new combo box to select the module type you want to create, the same fields for description of the field.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-cyan-blue-color has-css-opacity has-vivid-cyan-blue-background-color has-background\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Adding files to template<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Following the <strong>.plist<\/strong> file you need to create different folder structure and files that structured as the combo box items, for instance:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you select &#8220;<strong>XIB<\/strong>&#8221; as interface and &#8220;<strong>Struct<\/strong>&#8221; as type, you need to create a new folder called &#8220;<strong>XIBStruct<\/strong>&#8221; and put inside your files. In this case, you should put inside a <em>new XIB<\/em> and a <em>new Swift<\/em> file.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Every file you create in that folder should be called &#8220;<strong>___FILEBASENAME___ViewController.xib<\/strong>&#8221; and &#8220;<strong>___FILEBASENAME___.swift<\/strong>&#8221; and so on&#8230; you can add the files you prefer.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The variable &#8220;<strong>___FILEBASENAME___<\/strong>&#8221; will be replaced with the <strong>module name<\/strong> that you choose before.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Repeat this operation for all of your options. Your final result must be something like this:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1524\" height=\"686\" src=\"https:\/\/i1.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-20.04.03.png?fit=525%2C236&amp;ssl=1\" alt=\"\" class=\"wp-image-2148\" srcset=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-20.04.03.png?w=1524&amp;ssl=1 1524w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-20.04.03.png?resize=300%2C135&amp;ssl=1 300w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-20.04.03.png?resize=1024%2C461&amp;ssl=1 1024w, https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-20.04.03.png?resize=768%2C346&amp;ssl=1 768w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">Every file can change dynamically its contents using custom variables. Please refer to the original XCode files if you need inspiration but basically the format is like this:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"swift\" class=\"language-swift\">\/\/\n\/\/  ___FILENAME___\n\/\/  ___PROJECTNAME___\n\/\/\n\/\/  Created by ___FULLUSERNAME___ on ___DATE___.\n\/\/  Copyright (c) ___YEAR___ ___ORGANIZATIONNAME___. All rights reserved.\n\/\/\n\nimport UIKit\n\nfinal class ___VARIABLE_moduleName___ViewController: UIViewController {\n    \n    \/\/ @IBOutlet weak var &lt;#name#&gt;: UI&lt;#Type#&gt;!\n\n    override func viewDidLoad() {\n        super.viewDidLoad()\n    }\n\n    \/\/ ---------------------------------------------------------------------------------------------\n\n    \/\/ @IBAction func &lt;#actionName#&gt;(_ sender: &lt;#Any#&gt;) {}\n\n}\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Every variable that starts with the 3 underscores, like <strong>___<em>FILENAME<\/em>__<\/strong>_ will be replaced by XCode with the right value.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Customize your file and create your structure.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-cyan-blue-color has-css-opacity has-vivid-cyan-blue-background-color has-background\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Adding the template icon<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The icons must be named:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>TemplateIcon<\/strong>@3x.png<\/li>\n\n\n\n<li><strong>TemplateIcon<\/strong>@2x.png<\/li>\n\n\n\n<li><strong>TemplateIcon<\/strong>.png<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">No particular limitation about the size, consider that is an icon&#8230;<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Add these icons to the root folder, the same as the TemplateInfo.plist and the structured folders with your files.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-text-color has-vivid-cyan-blue-color has-css-opacity has-vivid-cyan-blue-background-color has-background\"\/>\n\n\n\n<h3 class=\"wp-block-heading\">Add custom template to XCode<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Well, your template is now ready. You can test it!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open the template folder, this one:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">\/Applications\/Xcode.app\/Contents\/Developer\/Platforms\/iPhoneOS.platform\/Developer\/Library\/Xcode\/Templates\/File Templates\/Source<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">And copy your root folder, the previous one (<strong>Custom Swift.xctemplate<\/strong>) to the &#8220;<strong>Source<\/strong>&#8221; folder.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open Xcode project,  create a new file and select your freshly created template. It should works as expected.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You can add the template you want, the UI you need, the continuous integration files, and all of the stuff that you use continuously in your projects.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\">Enjoy templating!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Very often you create a new class or a new view controller and customize it before start coding. Every time you select from XCode, New File, the file type and add it to your project, like this:<\/p>\n","protected":false},"author":1,"featured_media":2092,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[217,1,763,12,11,2,3,42,30],"tags":[480,886,887,889,274,888,885,894,890,891,892,893],"class_list":["post-2082","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-development","category-generic","category-ios","category-macos","category-mobile","category-objectivec","category-swift","category-unit-test","category-xcode","tag-custom","tag-custom-file","tag-custom-format","tag-custom-template","tag-extension","tag-new-file","tag-template","tag-templateicon","tag-templateinfo-plist","tag-xctemplate","tag-___filebasename___","tag-___filename___"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.7 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Create your own XCode template - while (true) {\u00a0}<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Create your own XCode template - while (true) {\u00a0}\" \/>\n<meta property=\"og:description\" content=\"Very often you create a new class or a new view controller and customize it before start coding. Every time you select from XCode, New File, the file type and add it to your project, like this:\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/\" \/>\n<meta property=\"og:site_name\" content=\"while (true) {\u00a0}\" \/>\n<meta property=\"article:published_time\" content=\"2020-06-14T18:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-06-26T13:52:35+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1\" \/>\n\t<meta property=\"og:image:width\" content=\"1528\" \/>\n\t<meta property=\"og:image:height\" content=\"1124\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Alberto Pasca\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@lupasca\" \/>\n<meta name=\"twitter:site\" content=\"@lupasca\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alberto Pasca\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/\"},\"author\":{\"name\":\"Alberto Pasca\",\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/#\\\/schema\\\/person\\\/d3cf0df774eb4aac797f246a795e9fac\"},\"headline\":\"Create your own XCode template\",\"datePublished\":\"2020-06-14T18:00:00+00:00\",\"dateModified\":\"2023-06-26T13:52:35+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/\"},\"wordCount\":664,\"publisher\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/#\\\/schema\\\/person\\\/d3cf0df774eb4aac797f246a795e9fac\"},\"image\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/www.albertopasca.it\\\/whiletrue\\\/wp-content\\\/uploads\\\/2020\\\/03\\\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1\",\"keywords\":[\"custom\",\"custom file\",\"custom format\",\"custom template\",\"extension\",\"new file\",\"template\",\"TemplateIcon\",\"TemplateInfo.plist\",\"xctemplate\",\"___FILEBASENAME___\",\"___FILENAME___\"],\"articleSection\":[\"development\",\"generic\",\"ios\",\"macOS\",\"mobile\",\"objectivec\",\"swift\",\"unit-test\",\"xcode\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/\",\"url\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/\",\"name\":\"Create your own XCode template - while (true) {\u00a0}\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/www.albertopasca.it\\\/whiletrue\\\/wp-content\\\/uploads\\\/2020\\\/03\\\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1\",\"datePublished\":\"2020-06-14T18:00:00+00:00\",\"dateModified\":\"2023-06-26T13:52:35+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/#primaryimage\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/www.albertopasca.it\\\/whiletrue\\\/wp-content\\\/uploads\\\/2020\\\/03\\\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/www.albertopasca.it\\\/whiletrue\\\/wp-content\\\/uploads\\\/2020\\\/03\\\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1\",\"width\":1528,\"height\":1124},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/create-your-own-xcode-template\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create your own XCode template\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/#website\",\"url\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/\",\"name\":\"while (true) {\u00a0}\",\"description\":\"notes from a developer, tutorials, how-to, ideas\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/#\\\/schema\\\/person\\\/d3cf0df774eb4aac797f246a795e9fac\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/www.albertopasca.it\\\/whiletrue\\\/#\\\/schema\\\/person\\\/d3cf0df774eb4aac797f246a795e9fac\",\"name\":\"Alberto Pasca\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g\",\"caption\":\"Alberto Pasca\"},\"logo\":{\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g\"},\"description\":\"Software engineer @ Pirelli &amp; C. S.p.A. with a strong passion for mobile \uf8ff development, security, and connected things.\",\"sameAs\":[\"https:\\\/\\\/www.albertopasca.it\",\"albertopasca\",\"https:\\\/\\\/x.com\\\/lupasca\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Create your own XCode template - while (true) {\u00a0}","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/","og_locale":"en_US","og_type":"article","og_title":"Create your own XCode template - while (true) {\u00a0}","og_description":"Very often you create a new class or a new view controller and customize it before start coding. Every time you select from XCode, New File, the file type and add it to your project, like this:","og_url":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/","og_site_name":"while (true) {\u00a0}","article_published_time":"2020-06-14T18:00:00+00:00","article_modified_time":"2023-06-26T13:52:35+00:00","og_image":[{"width":1528,"height":1124,"url":"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1","type":"image\/png"}],"author":"Alberto Pasca","twitter_card":"summary_large_image","twitter_creator":"@lupasca","twitter_site":"@lupasca","twitter_misc":{"Written by":"Alberto Pasca","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/#article","isPartOf":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/"},"author":{"name":"Alberto Pasca","@id":"https:\/\/www.albertopasca.it\/whiletrue\/#\/schema\/person\/d3cf0df774eb4aac797f246a795e9fac"},"headline":"Create your own XCode template","datePublished":"2020-06-14T18:00:00+00:00","dateModified":"2023-06-26T13:52:35+00:00","mainEntityOfPage":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/"},"wordCount":664,"publisher":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/#\/schema\/person\/d3cf0df774eb4aac797f246a795e9fac"},"image":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1","keywords":["custom","custom file","custom format","custom template","extension","new file","template","TemplateIcon","TemplateInfo.plist","xctemplate","___FILEBASENAME___","___FILENAME___"],"articleSection":["development","generic","ios","macOS","mobile","objectivec","swift","unit-test","xcode"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/","url":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/","name":"Create your own XCode template - while (true) {\u00a0}","isPartOf":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/#primaryimage"},"image":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1","datePublished":"2020-06-14T18:00:00+00:00","dateModified":"2023-06-26T13:52:35+00:00","breadcrumb":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/#primaryimage","url":"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1","contentUrl":"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1","width":1528,"height":1124},{"@type":"BreadcrumbList","@id":"https:\/\/www.albertopasca.it\/whiletrue\/create-your-own-xcode-template\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.albertopasca.it\/whiletrue\/"},{"@type":"ListItem","position":2,"name":"Create your own XCode template"}]},{"@type":"WebSite","@id":"https:\/\/www.albertopasca.it\/whiletrue\/#website","url":"https:\/\/www.albertopasca.it\/whiletrue\/","name":"while (true) {\u00a0}","description":"notes from a developer, tutorials, how-to, ideas","publisher":{"@id":"https:\/\/www.albertopasca.it\/whiletrue\/#\/schema\/person\/d3cf0df774eb4aac797f246a795e9fac"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.albertopasca.it\/whiletrue\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/www.albertopasca.it\/whiletrue\/#\/schema\/person\/d3cf0df774eb4aac797f246a795e9fac","name":"Alberto Pasca","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g","caption":"Alberto Pasca"},"logo":{"@id":"https:\/\/secure.gravatar.com\/avatar\/4d8fe43c412d0bb34a71c41f60dce53eff3afc027853cbfd20bee6ddc7e93f35?s=96&d=retro&r=g"},"description":"Software engineer @ Pirelli &amp; C. S.p.A. with a strong passion for mobile \uf8ff development, security, and connected things.","sameAs":["https:\/\/www.albertopasca.it","albertopasca","https:\/\/x.com\/lupasca"]}]}},"jetpack_publicize_connections":[],"jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"jetpack-related-posts":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/www.albertopasca.it\/whiletrue\/wp-content\/uploads\/2020\/03\/Schermata-2020-03-27-alle-16.03.31.png?fit=1528%2C1124&ssl=1","_links":{"self":[{"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/posts\/2082","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/comments?post=2082"}],"version-history":[{"count":89,"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/posts\/2082\/revisions"}],"predecessor-version":[{"id":3388,"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/posts\/2082\/revisions\/3388"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/media\/2092"}],"wp:attachment":[{"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/media?parent=2082"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/categories?post=2082"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.albertopasca.it\/whiletrue\/wp-json\/wp\/v2\/tags?post=2082"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}