October 29th, 2018
In Xcode 10 you no longer need to hold down the Option key to clean the build folder. You can just choose Product > Clean Build Folder.
October 24th, 2018
If you create a document-based app project in Xcode, select the app target in the project editor, and click the Info button, you will see sections for imported and exported UTIs. If you have any of the following questions:
Keep reading because this articles answers those questions.
A UTI is a Uniform Type Identifier that uniquely identifies a file type. Apple has a list of system-declared UTIs, but it’s not being actively maintained. For example a plain text file has the UTI
public.plain-text. Most common file types have
public at the start of their UTIs.
If you create a new file type, you must create a UTI for it. The UTI should take the form
Use imported UTIs when your app edits file types that it doesn’t own. Suppose you’re developing an image editor. Your image editor edits image files in multiple file formats, such as PNG, JPEG, and TIFF. You would add an imported UTI for each file type the image editor can edit.
Use an exported UTI for any file types your app owns. When you create a new file type for your app’s documents, your app owns that file type, and you should create an exported UTI for the file type. The exported UTI lets the operating system and other apps know about the new file type.
October 19th, 2018
I want to let you know about a new site I launched, Swift Dev Journal. Swift Dev Journal has articles to help iOS and Mac developers create apps in Swift.
None of the blog posts here are moving. Regarding future writing, longer articles and tutorials about iOS and Mac development will be on Swift Dev Journal. This blog will contain tips and shorter articles, such as the changes in new versions of Xcode, as well as articles that wouldn’t fit at Swift Dev Journal.
October 1st, 2018
In Xcode 10 projects use the new build system by default. If you want to use the legacy build system in a project, choose File > Project Settings. Choose Legacy Build System from the Build System menu.
September 27th, 2018
If your Xcode project is under version control, Xcode’s editor highlights the changes you make to the code. When you add or change code, Xcode places a blue bar on the left edge of the editor.
Clicking the blue bar opens a popover to discard the change. For some reason you can’t commit changes from the editor. You can only discard changes.
If you remove code, there may be a blue dot instead of a blue bar in the editor. Click the dot to discard the change and restore the code you removed.
The blue bar on the left side of the editor window is the most common color you’ll see. But Xcode also has the following color bars for source control changes:
If you do not see colored bars on the left side of the editor, you may need to turn on showing source control changes from Xcode’s Source Control preferences.
Make sure the Show Source Control changes checkbox is selected. Select the Include upstream changes checkbox to see upstream changes in the editor.