The default SVN install on Mac OS X uses neon. Neon allows you to connect to remote SVN repositories via HTTP and HTTPS. Lines 2-6 installs neon. Line 8 builds SVN using the –with-neon configuration flag. A task has emerged to install latest subversion for a group of mac os x users (latest mac os version). I have tried first to install it manually from subversion.tigris.org, 'opencollabnet binary' (.
I wrote an article about a year ago, about svn (Subversion) being missing in Mountain Lion (10.8) and how to install it manually. Since then, I’ve got a new mac and have used myself this post to install it on the new machine. Since then there has also been new versions of subversion but unfortunately all my software are not compatible with it. So I’ve been looking into this topic again and wanted to share.
Cached
Another way to install svn on mac is to use a ditribution package from wandisco. They are available here. Do not use the packages on CollabNet which are outdated.
Unzip the .pkg file and double click on it and follow the instructions to have it installed.
I still like it better with Homebrew since it makes it very easy to upgrade the packages and switch between packages.
To find out the version currently active with Homebrew:
You can check the versions of subversion which are available using:
This will return multiple lines, one per version, each containing a version number and the checkout command e.g.:
Choose the version you want to install e.g. here 1.8.1, switch Homebrew’s prefix,checkout the package and install it:
Then reset the formula:
You can then switch between versions using brew switch (which updates the symlink in /usr/local/bin to the specified formula version in the Homebrew cellar) e.g.:
Of course mechanism can be used for any other Homebrew package.
If you get errors in XCode while accessing working copies created with a newer version, you might need to link the newer version into XCode by doing the following:
- Create a backup directory for the svn binaries currently used by XCode
- Moving the current binaries to the backup folder
- Linking the binaries of the new version installed with Homebrew into Xcode (as a replacement for the moved ones)
You can do that by executing the following and replacing 1.7.4 by the actual subversion version you want to use in XCode:
Note that you can also use Homebrew-versions instead. It provides multiple formulas for different versions of existing packages e.g. subversion1.6 and subversion1.7. If you use it, you will of course not be able to upgrade from 1.7 to 1.8 but only from 1.7.2 to 1.7.3 but it’s maybe what you are after…
You can install from Homebrew-versions using:
You’ll notice that Homebrew-versions only has packages for subversion 1.6 and 1.7. But I guess 1.8 should come soon.
So there are quite a few ways to install subversion on your mac and handle different versions. The one I like best is still just installing it with Homebrew and switching to the one I use most. The other versions are still available by other switching to a particular version as shown above or by using the svn command from a particular version in the Homebrew Cellar e.g.
Related posts:
Mac OS X Server 10.6 Snow Leopard
The following is a summary of recipes found on the Web, adapted to our site.
If not already done so, enable Web service in the General settings of your server.
Become root:
sudo -s
.Create a folder holding the SVN repositories. We are using
/Volumes/Data2/Library/Subversion/Repository
.In Terminal, create a new SVN repository, for example
svnadmin create /Volumes/Data2/Library/Subversion/Repository/basis
.Finally, adjust ownership and permissions:
- Open Server Admin, select Web service.
Enable the dav_svn_module
Create a new site. We are using port 443 (SSL) here. Note: Either hostname or port must be unique in the list of sites hosted.
Enable WebDAV for the site under the options tab.
Enable SSL under the Security tab.
Define a WebDAV realm for the repository. Click the Plus button under the left-hand list in the Realms section and edit the corresponding entries as shown here.
Using the Plus button under the list on the right-hand side, add users and groups, giving them read and write permissions. Make sure that the permissions of the group Everyone is set to None.
Mac Svn
- Click Save to save the new site. Do not yet start or restart Web service.
Os Version
Back in Terminal, edit /etc/apache2/sites/0001_any_443_svn.cpfs.mpg.de.conf
. In the /svn/
location block near the end of the file, insert the lines
Latest Version Of Os X
Save your changes, return to Server Admin, and start or restart Web service.With Safari, connect to https://svn.cpfs.mpg.de/svn/basis/. After accepting the certificate and authenticating with the server, you should see something like this:
Subversion For Mac Os Versions
Caveat: If you apply further modifications to the SVN site just created using Server Admin, it might happen, that the line DAV yes in the configuration file is set to DAV no. Just in case there are problems with the access to the repository, correct this mistake and restart Web service.