Using Apple’s Xcode with an *existing* Subversion Project

The articles and howto’s that I found (“Using Subversion with Xcode” and
“Getting Control with Subversion and Xcode”) regarding integrating the Subversion source code version control system and apple‘s Xcode portion of their “Tools Suite” have all been geared, primarily, towards starting a *new* project with the tools. And while the methodology isn’t really that different when you’re looking to start using Xcode on an already existing (and under development) project it’s shifted one step to the left enough that it’s not… exactly… straightforward how you should accomplish this when you’re reading the classical google’d howto’s… So… Here…

We’ll assume the following:

  • OSX 10.4
  • Xcode 2.0 is installed and working
  • You know how to check out your repository remotely
    • hereafter referred to as “$repo”

That said, heres how you do it

  • Install Fink for OSX
  • At the command line:
    • $ sudo apt-get install svn
    • $ sudo apt-get install svn-client
    • $ cd ~
    • $ svn co $repo ./xcode-project
  • Create a new “Empty Project”
  • Set the “Project Directory” to “~/xcode-project/”
  • Once the project is created:
  • First — Add the existing project files:
    • Project -> “Add to Project”
    • Browse to your xcode-project directory
    • Apple-A to select all of the files in that directory
    • Click “Add”
    • Change “Reference Type:” from “Default” to “Relative to Enclosing Group”
    • Click “Add”
  • Second — Enable Xcode’s “SCM” Functionality:
    • File -> Get Info
    • Set “SCM System” to “Subversion”
    • Click “Edit”
      • Set “Subversion Tool Path:” to “/sw/bin/svn”
      • Click “OK”
    • Check “Enable SCM”
  • Now you’re Done

Once you’ve enabled this functionality you’ll have the SCM menu’s

  • Up top
  • In the right click menu’s
  • On the left under “Groups & Files”

Now… *HOW* to work with it… see… thats all you 😉

Cheers

DK

One thought on “Using Apple’s Xcode with an *existing* Subversion Project

Leave a Reply