Uli's Web Site
[ Zathras.de - Uli's Web Site ]
Other Sites: Stories
Abi 2000
Stargate: Resurgence
Lost? Site Map!
     home | blog | moose | programming | articles >> blog

 Blog Topics

15 Most Recent [RSS]

 Less work through Xcode and shell scripts
2011-12-16 @600
 iTunesCantComplain released
2011-10-28 @954
 Dennis Ritchie deceased
2011-10-13 @359
 Thank you, Steve.
2011-10-06 @374
 Cocoa Text System everywhere...
2011-03-27 @788
 Blog migration
2011-01-29 @520
 All you need to know about the Mac keyboard
2010-08-09 @488
 Review: Sherlock
2010-07-31 @978
 Playing with Objective C on Debian
2010-05-08 @456
 Fruit vs. Obst
2010-05-08 @439
 Mixed-language ambiguity
2010-04-15 @994
 Uli's 12:07 AM Law
2010-04-12 @881
 Uli's 1:24 AM Law
2010-04-12 @874
 Uli's 6:28 AM Law
2010-04-12 @869
 Uli's 3:57 PM Law
2010-04-12 @867


Subverting your Mac

Okay. Here I have my trusty old iBook with its broken screen back, and I'm going to use it as a server. First thing to install: Subversion. Subversion is a concurrent versioning system (like CVS), and apart from being a great tool if you have several people working on the same project, it is a neat way for people working alone to keep backups of all their source code easily, with the ability to roll back to any older version.
So, what do I do to install subversion? Well, first, I'm going to get subversion. You can get the server from Wilfredo Sanchez's iDisk (Finder: "Go to" -> "iDisk" -> "Other user's Public folder..." Username "wsanchez" and then navigate into "Software/packages/"). According to O'Reilly's MacDevCenter you need

  • BerkeleyDB
  • Expat
  • Libxml2
  • Neon
  • SWIG
  • APR
  • APR-util
  • Apache2
  • Subversion
And once you've installed those, O'Reilly's article will guide you through setting up the server.

For the client on your other Macs, there's a nice subversion .pkg installer at:


which is the web site of famous SubEthaEdit (fka Hydra) developer Martin Ott. In addition, you'll want to get SCPlugin, which is a plugin that adds "Subversion" menu items to your Finder's context menu.

This should save you some command-line-typing when committing/checking in your files. Note that SCplugin is configured via "System Preferences", where it also expects you to specify the path to subversion (/opt/subversion/bin/svn, if you're using Martin Ott's package). You also need to turn SCPlugin on there.

Once you've done that, check out your repository into a folder (using SCPlugin's "checkout" command). It will be empty, I know. Then just add all the files you want in your repository to that folder. Usually, you'll want a hierarchy with three folders per project: "trunk" (where your files go) and "tags" and "branches" you can leave empty until you're more familiar with Subversion. You can put other folders around the project folders and inside "trunk" however you please. E.g. my setup is:

  . . .

Where I copied the actual files (everything except the "build" folder) into each "trunk" folder. Once you've done that, you can do a "Select All" on the lowest level and an "Add..." in SCPlugin's contextual menu. Then do a "Commit" in the same place and you'll have your files in the repository.

If you're using xCode or Project Builder for most of your projects, you'll also want to heed Bill Bumgarner's advice on managing .pbxuser files in your xCode projects.

That's pretty much it. Between this, the O'Reilly article and the Subversion book, that should get you started :-)

Update: I wrote some more articles on Subversion that you may want to read. In particular, those are an Addendum to this one, a warning about checking in folders with custom icons, a Link to scripts for easily working with multiple files, and another with Links to using DarwinPorts to get SVN and more.

And also, I just started working on MAS, which is an attempt to bring a Subversion server to the Mac as a drop-installable application with a little GUI for starting/stopping it, not unlike MAMP.

Reader Comments: (RSS Feed)
No comments yet
Or E-Mail Uli privately.

Created: 2004-10-12 @727 Last change: 2006-07-16 @148 | Home | Admin | Edit
© Copyright 2003-2023 by M. Uli Kusterer, all rights reserved.