Use Subversion with OS X
Purpose
This how to is designed to introduce you to using Subversion on OS X. It is targeted at users of the CSE subversion server.
Prerequisities
For any of the following to make sense it would help if you are using OS X on your workstation. You must also have access to a project housed on the CSE subversion server that is tied to the campus kerberos.
Your project URL will look something like this: https://svn.cse.ucdavis.edu/repo/projectname.
Step by step
To use subversion on OS X you must install a few open source programs.
Install Xcode
Xcode is the name of the developers toolset from Apple. It should be included on your installation media. You can also download if from Apple's developer website.Install Subversion
To install subversion on OS X you can build it yourself from source code (which isn't all that fun) or you can download pre-built binaries from the folks at open.collab.net. Go to this download page, click on the big Download button and follow the on screen instructions.Install MIT Kerberos Extras
Although OS X by default has Kerberos support it doesn't make it easy to use. The MIT Kerberos Extras available here fix some of these issues.Configure OS X to use Kerberos
After you have everything above installed you need to configure Kerberos to authenticate from UC Davis Kerberos servers. As superuser (use sudo) edit the /Library/Preferences/edu.mit.Kerberos file to look like so:[libdefaults]
default_realm = UCDAVIS.EDU
noaddresses = TRUE
[realms]
UCDAVIS.EDU = {
kdc = auth1.ucdavis.edu.
kdc = auth2.ucdavis.edu.
admin_server = auth1.ucdavis.edu.
default_domain = ucdavis.edu
}
[domain_realms]
.ucdavis.edu = UCDAVIS.EDU
ucdavis.edu = UCDAVIS.EDU
[v4 realms]
[v4 domain_realm]
Testing Kerberos
Now that you have all the necessary tools installed it is time to test things out. Open up the Kerberos application (Applications -> Utilities -> Kerberos). Click the New button and enter your password into the following dialog:

If you entered your correct password you will get a TGT:

The above screenshot shows a TGT that is active for ten hours. You can also use the command line to get a TGT:
$ kinit sbeards
Please enter the password for sbeards@UCDAVIS.EDU: ****************
$ klist
Kerberos 5 ticket cache: 'API:Initial default ccache'
Default principal: sbeards@UCDAVIS.EDU
Valid Starting Expires Service Principal
11/28/07 17:09:27 11/29/07 03:09:19 krbtgt/UCDAVIS.EDU@UCDAVIS.EDU
renew until 12/05/07 17:09:19
klist: No Kerberos 4 tickets in credentials cache
$ kdestroy
$ klist
klist: No Kerberos 5 tickets in credentials cache
klist: No Kerberos 4 tickets in credentials cache
$
Testing Subversion
Once you have Kerberos working you can test Subversion with Kerberos. To do so get a TGT using kinit or the Kerberos GUI (shown above). Then use your project repo URL to list the contents:
$ kinit sbeards
Please enter the password for sbeards@UCDAVIS.EDU: ****************
$ svn ls https://svn.cse.ucdavis.edu/repo/projectname
branches/
tags/
trunk/
$
Optional: Install SCPlugin
You should also consider installing SCPlugin for Finder. This will allow you to right mouse click in finder and sync/upload/add/etc files and directories directly to the subversion server without dropping to a console. Make sure you use version 0.7.1 or newer. Kerberos support was added in late 2007.
see also:
-
Use Subversion at CSE
- How to use Subversion at CSE