Building an iOS App Without Xcode's Build System

A build system, despite its scary-sounding name, is just a regular program, which knows how to build other programs. As an iOS developer, you’re certainly familiar with how to build a project using Xcode. You go to the Product menu and select Build, or you use the ⌘B keyboard shortcut.

You may have also heard about Xcode Command Line Tools. It’s a set of tools which allows you to build Xcode projects directly from the terminal using the xcodebuild command. A very convenient thing for automating your processes, for example on your CI.

Build System

No matter how you’ve initiated it, the building itself is orchestrated by Xcode’s build system.

Can we replicate the building process and build the app “manually”, without Xcode’s build system?

Is it possible to sign the resulting app? Or even deploy it to an actual iOS device?

Continue reading ....

What's inside the Derived Data folder?

Deleting derived data - a well know trick that comes in handy every time Xcode behaves strangely for no obvious reason. I still clearly remember when my senior told me about this basic iOS dev trick for the first time.

Derived Data folder

As years went by, and with more experience gained, I started to understand what kind of errors can be fixed like that. However, I never really understood what exactly is inside the DerivedData folder. I decided to change that and here are my findings.

Continue reading ....

Namespacing UITableView and Where to Draw the Line

Objective-C was the first programming language I learned and used professionally. One of the first things you need understand, when working with ObjC, is the lack of namespaces. The whole Objective-C runtime acts like one namespace. To prevent name collisions, Objective-C uses name prefixes. You simply create your own pseudo-namespace by prefixing all your class’ names. That’s the reason why we have names like UIView, NSObject and MKMapView.


Swift has module defined namespaces so name prefixes are not needed anymore. I have to say I miss them. Having your initials as a part of your class’ name brings a strangely satisfying feeling of ownership.

Let’s do a little thought experiment. UITableView is one of the keystones of iOS development. Introduced in iOS 2.0, it’s one of the oldest API we still actively use. What could UITableView API names look like if it was introduced in 2017 with Swift only support? Let’s play around with namespacing.

Continue reading ....

How I didn't become a SoundClouder

At the end of March 2017, I decided to leave Concur. I had been working there for a year and I had a lot of fun with great teammates around me. However, the project I was working on was canceled in the beginning of the year. The new assignment we got was completely different from the one I joined the company for in the first place. So I started to look around for new opportunities.

SoundCloud logo

I sent my CV to SoundCloud in April and got an immediate response from a recruiter. We had a 20-minute Skype call when she asked me basic questions about my history and motivation. I asked her specifically about the financial stability of the company, since in the beginning of the year, SoundCloud announced it might run out of money. She told me the situation was bad but it was solved. She said: “if I didn’t believe in the future of the company, I wouldn’t work here”. I believe she wasn’t lying. She had no idea what was about to come.

Continue reading ....

Organize your errors

There are two types or programmers: Those who handle errors properly, and those you don’t want to work with.

Windows BSOD

It’s happening over and over again. Something has stopped working and I need to fix it. After tens of minutes of debugging and diving deeper into the code base, I finally find it. Someone (including several-years-ago myself), ignored an error and left it unhandled.

Continue reading ....

CocoaHeadsCZ officially started 🎉

The CocoaHeadsCZ opening party happened on 6.4.2017 and we had a lot of fun!

Opening party

We met at a lovely place called Bistro Arte. We managed to discuss a lot of important things for the future of CocoaHeads in Prague, and also had a couple of beers.

Continue reading ....

Array Rotation - Programming Interview Problem (II.)

Today, we’re going to focus on another famous programming interview problem - Array rotation. We start with a simple “obvious” solution and move to more optimized and interesting one afterwards.

Why did programmer quit his job?

The problem: Rotate an array of n elements to the right by k steps. For example, with n = 6 and k = 3, the array [1,2,3,4,5,6] is rotated to [4,5,6,1,2,3].

Continue reading ....

Hamming Distance - Programming Interview Problem (I.)

This is the first post of a small series focused on common technical interview challenges. You can find a lot of articles and StackOverflow answers on the similar topic. However, I would like to focus on a Swift-first approach and detailed explanation. Fore the sake of curiosity, I will also show an Objective-C version of the final algorithm. I’m going to use problems from the awesome website LeetCode. So let’s start!

Hamming distance - 3 bits (Image source: Wikipedia)

The problem: Given two integers x and y, calculate the Hamming distance. The Hamming distance between two integers is the number of positions at which the corresponding bits are different.

Continue reading ....