<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Using diff and patch to upgrade web application installations</title>
	<atom:link href="http://blog.bigsmoke.us/2008/03/13/upgrading-web-apps-with-diff-and-patch/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.bigsmoke.us/2008/03/13/upgrading-web-apps-with-diff-and-patch</link>
	<description>Smokes your problems, coughs fresh air.</description>
	<lastBuildDate>Thu, 08 Jul 2010 10:29:32 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
	<item>
		<title>By: Rowan Rodrik</title>
		<link>http://blog.bigsmoke.us/2008/03/13/upgrading-web-apps-with-diff-and-patch#comment-90523</link>
		<dc:creator>Rowan Rodrik</dc:creator>
		<pubDate>Wed, 13 Jan 2010 19:25:18 +0000</pubDate>
		<guid isPermaLink="false">http://blog.bigsmoke.us/2008/03/13/upgrading-web-apps-with-diff-and-patch#comment-90523</guid>
		<description>I just used diff and patch to upgrade a messy, old version of the Simple Tags plugin in this WordPress installation to a newer version.

&lt;code lang=&quot;bash&quot;&gt;
cd ~/blog.bigsmoke.us/wp-content/plugins
diff --unified  --recursive --exclude=.svn --new-file simple-tags new-simple-tags &gt;st-up.diff
cd simple-tags
patch -p1 --remove-empty-files &lt; ../st-up.diff
svn status&#124;sed -e &#039;/^\!/!d; s/^\!//&#039;&#124;xargs svn del
svn add inc
&lt;/code&gt;

I noticed that this still left a lot of old files hanging around, the same problem as I&#039;ve had the previously with this method. Also, some files wouldn&#039;t get patched. Instead of being mystified by this failure &lt;em&gt;again&lt;/em&gt;, I realized that diff and patch simply can&#039;t deal with binary files (beyond reporting whether they differ or not).

Now I&#039;m writing a simple script to use for future updates of this type. It&#039;s not that I need to be able to save space by storing just the differences or anything fancy like that. It&#039;s just that I can&#039;t replace the contents of the old directory with those of the new version, because Subversion insists on keeping those annoying &lt;tt&gt;.svn&lt;/tt&gt; subdirs everywhere in your working copy.</description>
		<content:encoded><![CDATA[<p>I just used diff and patch to upgrade a messy, old version of the Simple Tags plugin in this WordPress installation to a newer version.</p>
<p><pre class="bash"><span style="color: #000066;">cd</span> ~/blog.bigsmoke.us/wp-content/plugins
diff --unified  --recursive --<span style="color: #0000ff;">exclude=</span>.svn --new-file simple-tags new-simple-tags &gt;st-up.diff
<span style="color: #000066;">cd</span> simple-tags
patch -p1 --remove-empty-files &lt; ../st-up.diff
svn status|sed -e <span style="color: #ff0000;">'/^<span style="color: #000099; font-weight: bold;">\!</span>/!d; s/^<span style="color: #000099; font-weight: bold;">\!</span>//'</span>|xargs svn del
svn add inc</pre></p>
<p>I noticed that this still left a lot of old files hanging around, the same problem as I&#8217;ve had the previously with this method. Also, some files wouldn&#8217;t get patched. Instead of being mystified by this failure <em>again</em>, I realized that diff and patch simply can&#8217;t deal with binary files (beyond reporting whether they differ or not).</p>
<p>Now I&#8217;m writing a simple script to use for future updates of this type. It&#8217;s not that I need to be able to save space by storing just the differences or anything fancy like that. It&#8217;s just that I can&#8217;t replace the contents of the old directory with those of the new version, because Subversion insists on keeping those annoying <tt>.svn</tt> subdirs everywhere in your working copy.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: BigSmoke &#187; Untangling WordPress&#8217; core files from your local customizations</title>
		<link>http://blog.bigsmoke.us/2008/03/13/upgrading-web-apps-with-diff-and-patch#comment-74692</link>
		<dc:creator>BigSmoke &#187; Untangling WordPress&#8217; core files from your local customizations</dc:creator>
		<pubDate>Fri, 30 Jan 2009 21:40:20 +0000</pubDate>
		<guid isPermaLink="false">http://blog.bigsmoke.us/2008/03/13/upgrading-web-apps-with-diff-and-patch#comment-74692</guid>
		<description>[...] for my blogs and thus had to upgrade the old fashioned way with each release (although I prefer diff/patch over rm/cp). (I could have used vendor branches, but, clearly, I hadn&#8217;t thought about that at the time.) [...]</description>
		<content:encoded><![CDATA[<p>[...] for my blogs and thus had to upgrade the old fashioned way with each release (although I prefer diff/patch over rm/cp). (I could have used vendor branches, but, clearly, I hadn&#8217;t thought about that at the time.) [...]</p>
]]></content:encoded>
	</item>
</channel>
</rss>
