<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Tortoise IT &#187; Unix</title>
	<atom:link href="http://www.sean-barton.co.uk/tag/unix/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.sean-barton.co.uk</link>
	<description>by Sean Barton, a freelance PHP website developer in Crewe, Cheshire</description>
	<lastBuildDate>Tue, 31 Jan 2012 17:34:43 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>How to recursively remove .svn directories</title>
		<link>http://www.sean-barton.co.uk/2009/07/how-to-recursively-remove-svn-directories/</link>
		<comments>http://www.sean-barton.co.uk/2009/07/how-to-recursively-remove-svn-directories/#comments</comments>
		<pubDate>Thu, 23 Jul 2009 10:15:33 +0000</pubDate>
		<dc:creator>Sean</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[Subversion]]></category>
		<category><![CDATA[Time Savers]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Bat]]></category>
		<category><![CDATA[Macs]]></category>
		<category><![CDATA[Repository]]></category>
		<category><![CDATA[Sheer Laziness]]></category>
		<category><![CDATA[Unix]]></category>
		<category><![CDATA[Upload Files]]></category>

		<guid isPermaLink="false">http://www.sean-barton.co.uk/?p=304</guid>
		<description><![CDATA[Regular readers may have clocked onto the fact that I use Subversion. Well the way it works it to keep a hidden set of directories within your checked out repository. It uses this to track any changes etc.. Each directory is called &#8216;.svn&#8217; and is within each and every directory and subdirectory you have. The problem Now I know I am not alone in saying that when you want to upload the files to a remote server you have to do one of two things Upload the files and .svn directories to your server which is likely to take twice &#8230; <a class="continue_reading" href="http://www.sean-barton.co.uk/2009/07/how-to-recursively-remove-svn-directories/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Regular readers may have clocked onto the fact that I use Subversion. Well the way it works it to keep a hidden set of directories within your checked out repository. It uses this to track any changes etc.. Each directory is called &#8216;.svn&#8217; and is within each and every directory and subdirectory you have.</p>
<p><strong>The problem</strong></p>
<p>Now I know I am not alone in saying that when you want to upload the files to a remote server you have to do one of two things</p>
<ul>
<li>Upload the files and .svn directories to your server which is likely to take twice the time and twice the disk space</li>
<li>Make a separate local copy of your files and then remove the .svn directories one by one.</li>
</ul>
<p>I prefer to take option two although in recent months I have taken on the former through sheer laziness. I decided to look for a solution and found my answer&#8230;</p>
<p><strong>The answer</strong></p>
<p>For windows machines you need to create a secondary copy of your files to upload, this means it won&#8217;t wipe out your local repository files (the ones you want to keep). Next, create a &#8216;.bat&#8217; file (batch file for executable scripts). The simplest way to do this is to open notepad and doing <em>File &gt; Save as &gt; remove_svn.bat</em> after copying in the code below.  It needs to be saved in the root directory of your repository copy. This is important if not it will recurse all directories below the one it is placed in.</p>
<pre>for /f "tokens=* delims=" %%i in ('dir /s /b /a:d *svn') do (
  rd /s /q "%%i"
)</pre>
<p><em>I have done all the hard work for you on this one.<br />
Just click the following link: </em><a class="downloadlink" href="http://www.sean-barton.co.uk/wp-content/plugins/download-monitor/download.php?id=12" title="Version 1 downloaded 2124 times" >Remove SVN Files (Windows) (82 bytes)</a></p>
<p>For Macs and other Unix based machines you need to do something similar. This time we simply run a command on the shell (or create a shell script out of it). Again this must be placed in the directory you want to recurse through.</p>
<pre>find . -name .svn -print0 | xargs -0 rm -rf</pre>
<p><strong>The Credit</strong></p>
<p>Credit for these snippets goes to the following sites. Whether they were the original authors or not I don&#8217;t know but credit where credit is due etc..</p>
<p><em>Mac version</em> &#8211; http://snipplr.com/view/201/remove-all-svn-directories/<br />
<em>Windows Version</em> &#8211; http://bluespark.tumblr.com/post/23853870/remove-svn-subfolders-on-windows-xp-vista</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sean-barton.co.uk/2009/07/how-to-recursively-remove-svn-directories/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk
Page Caching using disk (enhanced)
Database Caching 8/18 queries in 0.050 seconds using disk
Object Caching 340/340 objects using disk

Served from: www.sean-barton.co.uk @ 2012-02-08 21:54:10 -->
