Helpful Tools for iOS Developers

By Mark Wilkinson | Jan 07, 2014

Imagine walking into the worksite for a new building.  You bring no tools and rely only on what was provided to you by your frugal contractor.  Within a short time and a looming deadline you’re required to put up the drywall, the electric wiring, plumbing and not to mention paint with the skeleton structure of the building already provided.

Welcome to the software development world of clients, tools, templates and deadlines.  These similar hurdles will be faced by anyone wanting to build quality applications whether on mobile, web or desktop with the resources available to you.  Luckily, most contractors and construction workers have the best tools available either provided to them or through their own initiative.  Electricians use their favorite multimeter, painters use a quality sprayer, and builders have a reliable tool belt with the right hammers, nail guns and so forth.  Software developers should be equally prepared when stepping into a new project with a set of tools and templates already in mind.

Just like professional construction workers don’t rely on hammer and nail starter kits from the local store, professional software developers shouldn’t rely solely on what an IDE gives you for end-to-end development. Many times, developers rely on popular (usually 3rd party) tools and templates to aid in the construction of quality software.

Apple development is no exception and there are more than enough tools for code completion, unit-testing, coding standards and 3rd party libraries. We’ll discuss each below.

Xcode Shortcuts

One of the most frustrating transitions when going from platform to platform like the .NET world on a PC to the Cocoa Touch world of the Mac, is re-learning the IDE wheel.  Everything will be different – shortcuts, menus, code-completion you name it.  Here are the most important shortcuts I found and needed coming from .NET and ReSharper:

  • ⌘+ctrl+J = go to definition of where the cursor resides (anything, variable, class, method)

  • ⌘+shft+J = drill down to the file you’re currently editing in the project navigator

  • ⌘+B = build

  • ⌘+R = run

  • ⌘+U = run your unit tests

  • ⌘+1 = show the project navigator

  • ⌘+0 = hide the project navigator (to give you more coding real estate)

  • ⌘+shft+O = search for and open any file, method, class

  • ctrl+6 = list, search and jump to a method within the file you’re currently editing

  • ⌘+shft+F = search for anything within the workspace and show the results

  • ⌘+ctrl+E = edit all in scope (my favorite and probably the biggest time saver)

These are just a few shortcuts you’ll need to learn to greatly increase your Xcode productivity. There’s a lot more like pane splitting to view and edit two files at once (great when you’re doing TDD) and jumping between those panes without touching your mouse.  Here’s two great blog posts listing all the shortcut features that Xcode provides that you wouldn’t find otherwise:

http://realmacsoftware.com/blog/xcode-4-s-less-obvious-shortcuts

http://www.git-tower.com/blog/6-tips-for-xcode/

Xcode Plugins

The second key to enhancing any IDE experience are plugins.  When I left Visual Studio, there was a very robust community of 3rd party plugins and even a nice plugin browser within Visual Studio.  Fret not, Xcode has this same option, meet Alcatraz:

As of this blog post, the Xcode 5 version is a work in progress that still doesn’t prevent you from installing plugins that Alcatraz can and will manage when it is Xcode 5 ready.

ColorSense for Xcode

I honestly can’t remember what I did before I found the ColorSense plugin and I wanted to manage the RGB values of color I was creating in code.  There’s really no need to explain this one, but it basically simplifies hacking around RGB values until you get the color you want.

Developer Color Picker

The above screenshot is also incorporating another must-have plugin, the Developer Color Picker.

The Intelligent Image Finder

Do you manually type in your image names when initializing a NSImage or UIImage?  Stop doing this and start using the KSImageNamed-Xcode plugin.  Put simply, this plugin uses intellisense to find your images stored locally in your project like so:

Cocoapods

The official, but really unofficial 3rd party library manager for Xcode is CocoaPods. Heavily inspired by Ruby Gems, CocoaPods is an easy to use command-line manager for adding other developers’ code into your projects to help you get things done faster.

Some notable libraries:

  • AFNetworking – the go-to library for quickly accessing web

  • DCIntrospect – makes it easy to see UIView coordinates while running in the simulator

  • MMProgressHUD – probably the coolest framework for popping up an animated progress spinner

  • SSKeychain – a simple wrapper around Keychain to let you set passwords and credentials

Developer Must-Haves

Those were just a small sample of resources available for Xcode and coding purposes.  Then you have your swiss army knife of Mac apps that enhance your development experience, here are a few:

  • iTerm – a nice alternative to the Terminal application

  • SublimeText – probably the slickest and most popular text editor available

  • Dash – one documentation app to rule them all (literally, all frameworks and languages in one app)

  • Status-Barred – when you need to crop the status bar of your iOS screenshots before submitting them to the app store

  • HttpClient – a mac only tool for creating and inspecting http calls and responses

  • Charles – another mac only app for monitoring and breaking down all http traffic on your machine

  • SourceTree – From the fine folks who brought you Bitbucket.com, a great Git/Mercurial app

  • AirMail – a mail app?  Yes, because when you need to manage multiple mail accounts this is one of the best options

Unit Testing

Are your monolithic code bases reliable, easy to extend and bug-free without any tests to back them up? Well…you’re a lot better developer than myself, but if you’re like me and constantly do not trust the logic in the code you write, then you need to use unit tests to verify every piece of functionality that you can.

Cocoa Touch and Objective-C are no exception and they can be unit tested from end-to-end.

Xcode 5 now ships with a new unit testing framework called XCTest, which is really just a much improved alternative to the previous framework SenTestKit.  If you prefer more fluent and behavior driven testing, then you’ll be pleased at the offerings:

  • Kiwi – an rspec like framework for BDD in Obj-c

  • OCMock – the de facto Mocking framework for Cocoa and Cocoa Touch

  • OCMockito – an alternative Mocking framework with a cool name

  • Specta – a newer BDD framework

  • Expecta – a fluent expectation and assertion framework that can be used with Specta or on its own inside SenTest and XCTest methods

Resources

This is only a brief summary of the most popular tools and tips. There are more exhaustive collections of iOS developer resources with the most prominent being Ben Sheirman’s 75 Essential Tools for iOS Developers.

In addition to that, I recommend my talk on Objective-C for C# Developers if you’re transitioning from the .NET world to Cocoa Touch.

Conclusion

Developing quality software requires tools, time and talent, the first of which should be a priority for every beginning developer. Getting started on the right footing with the right tooling, tips and tricks saves you invaluable time which in turn leads to increased productivity and knowledge you can then pass on to other developers.

ux_design

Get in touch

Marketo Form