Archive for the ‘Subversion’ Category

HOWTO: Add svn:externals in windows using tortoisesvn

4 June, 2009 2 comments

I have a few projects in subversion using the same set of third party tools nant, bdd, mbunit etc. I’ve read its a good idea to put the tools into their own repository and include them in the other projects using an svn:external. The advantage this gives you is any changes you make to the external repository can be updated easily across all projects. Any hoose this is who to do it.

  1. Go to the root of the folder you want to add the externals too.
  2. Right click on the root folder of the project you want to add the external repository to and select TortoiseSVN –> Properties.tortoise_settings[3]   Note: This folder has to be a checked out subversion repository or you’ll not get the context menu! 
  3. You will now see the subversion properties dialog.tortoise_properties[1]
  4. Click the New.. button. You will now see the Add properties dialog.tortoise_add_properties[1]
  5. Select svn:externals from the property name drop down list.
  6. Enter the name you want to give to the external folder followed by the path to your tools repository in property value text area.
    In the example above: tools svn://server/tools/trunk
    Note: You can add more external repositories by simply adding more lines to the property value text area.
  7. Click Ok to add the property will now be listed in the properties dialog.tortoise_properties2[1]
  8. Right click on the root folder and select SVN Update from the menu. Subversion will now pull down the files from the external repository and your done.

Once you check this change in other people checking out from the repository will automatically get the externals folder. Also any changes to the external repository will be updated in this repository on any update. So in this case if I add a new tool or update one of the tools all repositories using this external repository will get the changes on their next update.


  • Don’t forget to give the folder name before the repository address and not just the repository address or you will get an error along the lines of: Error parsing svn:externals property on …tortoise_error[1]
Categories: Subversion Tags:

Subversion, TortoiseSVN and the _SVN ASP.NET Hack

7 June, 2006 Comments off

Good write up of the TortoiseSVN ASP.NET Hack here

Basically involves creating an environment variable SVN_ASP_DOT_NET_HACK with the value of 1. When TortoiseSVN finds this variable it looks for _svn folder instead of .svn

Categories: Subversion

Ruby script to rename windows subversion files .svn to _svn

4 May, 2006 1 comment
Dir["**/.svn"].each do |folder|
	File.rename(folder, folder.sub('.svn', '_svn'))
Categories: Ruby, Subversion

Windows SubVersion / TortoiseSVN – Compare two versions of a file

26 April, 2006 6 comments

Today I needed to compare two different versions of a source file. One in the main trunk folder and the other in a previously tagged version folder. This is easily done in TortoiseSVN, snippet from the TortoiseSVN manual:

Compare two revisions of a file
If you want to compare two revisions in a file’s history, for example revisions 100 and 200 of the same file, just use TortoiseSVN => Show Log to list the revision history for that file. Pick the two revisions you want to compare then use Context Menu => Compare Revisions.

If you want to compare the same file in two different trees, for example the trunk and a branch, you can use the repository browser to open up both trees, select the file in both places, then use Context Menu => Compare Revisions.

If you want to compare two trees to see what has changed, for example the trunk and a tagged release, you can use TortoiseSVN => Revision Graph Select the two nodes to compare, then use Context Menu => Compare HEAD Revisions. This will show a list of changed files, and you can then select individual files to view the changes in detail. Alternatively use Context Menu => Unified Diff of HEAD Revisions to see a summary of all differences, with minimal context.

The process of comparing two trees is really nicely done, you get a list of all the files which have been changed between the two trees. You can then drill into this list and see the changes made to individual files. Kewl!

Categories: Subversion

Tagging in subversion

3 April, 2006 2 comments

We have started tagging our source when releasing to QA/porduction which means we can easily roll back to an ealier verison of the code if a problem is found in production. Here’s how we do it using TortoiseSVN.

First commit your source then open up the TortoiseSVN repository browser:

Right click in a folder in windows to get a context menu then select TortoiseSVN => Repo-Browser.

You should now see Repository browser:

Repository Browser

Find the trunk of the project you wish to tag then right click on the trunk folder and select ‘Copy to…’ from the context menu.

You will now see the Copy to… dialog:


Enter the path to your tagged copy, along the lines of svn://server/project/tags/Version2.00

You now have tagged version of your project which you can revert to anytime.

Categories: Subversion