Development, Mac OS, Obj-C, Programming

Objective-C Swizzling without Side Effects

<tl;dr> Using method_exchangeImplementations results in a number of unexpected and dangerous side effects which in most cases you’ll want to avoid. You should use method_setImplementation and swizzle a C-style function instead to give yourself more control over your applications behaviour. </tl;dr>   Swizzling is an incredibly powerful, and incredibly dangerous, feature of Objective-C that in… Continue reading Objective-C Swizzling without Side Effects

Mac OS, Obj-C, Programming, Unit Testing

Injecting data into Obj-C readonly properties

<tl;dr> If you want to inject data into an object that only has read-only properties, swizzle the synthesised getter function so you can inject the data you need at the point it’s accessed. For example </tl;dr>   I recently needed to set up some client side unit tests for our iOS receipt verification server. This… Continue reading Injecting data into Obj-C readonly properties

Accu, C++, Community, Conferences, Continuous Integration, Git, Unit Testing

Accu 2014 Conference Notes

I had the chance to go to ACCU 2014 the other week (full conference schedule is here) and I have to say it was one of the best conferences I've had the pleasure to attend. And while it did confirm my idea that C++ is getting the point of saturation and ridiculous excess (C++11 was… Continue reading Accu 2014 Conference Notes

Development, Git, Perforce

Git Off My Lawn – Large and Unmergable Assets

I posted up the Git talk myself and Andrew Fray did at Develop 2013 and mentioned I'd have a few follow up posts going into more detail where I thought it was probably needed (since you often can't get much from a slide deck and no-one recorded the talk). One of the most asked questions… Continue reading Git Off My Lawn – Large and Unmergable Assets

GLFW, Mac OS, Programming, XCode 4

GLFW – Compiling Source and Creating an Xcode Project

GLFW is a great library - easy to use, great documentation covering it's API design. But if you're not on Windows where they provide pre-built libraries, going from a source download to a compiling Xcode project is _not_easy. Since brew (as of writing) only provides GLFW 2, you need to build GLFW 3 yourself. There… Continue reading GLFW – Compiling Source and Creating an Xcode Project

Conferences, Develop, Development, Git, Perforce

Git Off My Lawn – Develop 2013

Recently myself and Andrew Fray (@tenpn) presented "Git Off My Lawn" at Develop 2013 in Brighton. The talk was designed to discuss how we took a Perforce centric development process and moved over to one centred around Git and a Git based branching work flow. As with most presentations the slides tell half (or less)… Continue reading Git Off My Lawn – Develop 2013

Development, Git

Git Fetch –prune and Branch Name Case

I posted up the following to the git community mailing list the other day When using git fetch --prune, git will remove any branches from remotes/origin/ that have inconsistent case in folder names. This issue has been verified in versions 1.7.10.2, 1.7.11.1 and 1.8.3.2. I've described the reproduction steps here as I carried them out,… Continue reading Git Fetch –prune and Branch Name Case

Perforce

Installing P4 on Mac OS…

...because for some reason installing P4V doesn't install the command line tool (and I'm tired of having to Google it). Download the command line client from Perforce - http://www.perforce.com/downloads Copy the downloaded file to /usr/local/bin/ Make the file executable by running the following in Terminal   cd /usr/local/bin/ chmod +x p4   Why Perforce can't… Continue reading Installing P4 on Mac OS…

Development, Management, People

Negative Developers and Team Stability

It doesn't take much for negative feelings to start to seep into a team but it takes a lot more to turn a team around and start to raise moral and motivation. The following isn't based on an in-depth study of development teams across the world but on my own personal experience of managing and… Continue reading Negative Developers and Team Stability

Continuous Integration, Jenkins, Mac OS, Ruby

Ruby, Jenkins and Mac OS

I've been using Jenkins as my CI server for a while and though user permissions has always been a bit of an issue (I'll explain why in another blog post covering my Unity build process) running command line tools has never been to much of a problem once it got going. At least not until… Continue reading Ruby, Jenkins and Mac OS