Linker command failed with exit code 1

September 6th, 2018

Filed under: Xcode | 1 comment

If you have done any programming in Xcode, you have come across the following error message when building your project: Linker command failed with exit code 1. This error message is frustrating because it tells you nothing besides the fact the linker command failed. You want to know what the real error is so you […]


Xcode Turns on the App Sandbox for New Cocoa Projects

July 11th, 2018

Filed under: Cocoa, Mac Development, Xcode | Be the first to comment!

I ran into an issue with a new document-based Cocoa app throwing exceptions when I tried to save the document. It turns out the issue was the App Sandbox, which is turned on when you create a new Cocoa application project in Xcode. You can see the App Sandbox settings by selecting your project from […]


Getting Started with Unit Testing in Swift 4

June 13th, 2018

Filed under: Cocoa, iOS Development, Mac Development, Xcode | Be the first to comment!

One of the most read articles on this blog is An Introduction to Swift Unit Testing. The article is almost four years old and uses Swift 1. Because of that I have decided to build upon that article here, updating the code to Swift 4 and adding an example project to unit test. The Project […]


Resources for Creating Custom Instruments with Xcode 10

June 11th, 2018

Filed under: Instruments, Xcode | Be the first to comment!

At WWDC 2018 Apple unveiled improved support for creating custom instruments for Instruments. The following list contains helpful resources from Apple on how to create custom instruments: The Creating Custom Instruments WWDC video is the best guide currently available for creating custom instruments. The Measuring Performance Using Logging WWDC video shows how to use logging […]


Xcode 9.3: Core Animation Instrument Deprecated

April 25th, 2018

Filed under: Instruments, Xcode | Be the first to comment!

Apple deprecated the Core Animation instrument in Xcode 9.3. If you’re looking for the debug options the Core Animation instrument had, use Xcode’s view debugger. Choose Debug > View Debugging > Rendering to access the debug options.


Xcode Releases Site

April 13th, 2018

Filed under: Xcode | Be the first to comment!

A common question I see on Apple developer forums is what version of Xcode can be used with a particular version of macOS. The Xcode Releases site provides the answer to this question. Xcode Releases lists every Xcode version Apple has ever released along with operating system requirements and download links. As you can see […]


Going Back to a Previous Git Commit in Xcode

March 12th, 2018

Filed under: Version Control, Xcode | Be the first to comment!

Something that can happen to you when using version control is you commit a change to the version control repository, realize you made a mistake, and want to go back to an earlier commit. How do you do this in Xcode? Xcode provides no direct way to go back to an earlier commit. What you […]


Ignoring Files That Are Already in a Git Repository

March 5th, 2018

Filed under: Version Control, Xcode | Be the first to comment!

In a previous post, I showed how to tell git to ignore files in Xcode projects. But what do you do if you want to ignore a file that git is currently tracking? Remove the file from the git repository. Add the file you want to ignore to the git ignore file. If you don’t […]


Telling Git to Ignore Files in Xcode Projects

February 28th, 2018

Filed under: Version Control, Xcode | Be the first to comment!

When you create a project in Xcode and create a git repository, git initially tracks every file in the project, but this behavior isn’t what you want. Xcode projects contain a lot of files. Some of these files shouldn’t be tracked by git because they change every time you build your project. Having files you […]


Xcode 9: Adding Your Project to GitHub

February 21st, 2018

Filed under: Version Control, Xcode | Be the first to comment!

Before Xcode 9, setting up your project to work on GitHub involved a lot of work. You had to login to GitHub, create a repository, go back to your Mac, launch the Terminal application, navigate to your project directory, and run multiple git commands. Xcode 9 makes working with GitHub much easier. You can add […]