<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>crunchlife: Subversion: Merging a Branch into Trunk</title>
    <link>http://crunchlife.com/articles/2009/08/25/subversion-merging-a-branch-into-trunk</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description></description>
    <item>
      <title>Subversion: Merging a Branch into Trunk</title>
      <description>&lt;p&gt;I can never remember how to merge a &lt;a href="http://subversion.tigris.org/" target="_blank"&gt;Subversion&lt;/a&gt; branch into trunk.  So for future reference, here is how it&amp;#8217;s done.&lt;/p&gt;

&lt;p&gt;First, get a working copy of the head revision of trunk.&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_default "&gt;svn checkout svn://svnserver/project/trunk project&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Next, merge the branch with your working copy.&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_default "&gt;svn merge svn://svnserver/project/trunk svn://svnserver/project/branches/branch project&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Finally, commit the results of the merge.&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_default "&gt;cd project
svn commit -m &amp;quot;Merging branch X.X.X into trunk.&amp;quot;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;You can also specify a revision number in your merge.&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_default "&gt;svn merge svn://svnserver/project/trunk@223 svn://svnserver/project/branches/branch@223 project&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;That&amp;#8217;s it.&lt;/p&gt;</description>
      <pubDate>Tue, 25 Aug 2009 18:21:00 -0700</pubDate>
      <guid isPermaLink="false">urn:uuid:32e934ca-5772-409a-a579-b8c7692c38b4</guid>
      <author>Ryan Baxter</author>
      <link>http://crunchlife.com/articles/2009/08/25/subversion-merging-a-branch-into-trunk</link>
      <category>Code Snippets</category>
      <category>Oops</category>
      <category>SCM</category>
      <category>SVN</category>
    </item>
    <item>
      <title>"Subversion: Merging a Branch into Trunk" by Ryan Baxter</title>
      <description>Joel - Yes, you should probably perform an update on a previously checked out trunk.  I'll add that to this post.</description>
      <pubDate>Mon, 08 Mar 2010 07:42:33 -0800</pubDate>
      <guid isPermaLink="false">urn:uuid:d4d0985a-2552-49e4-a73b-aecf22117503</guid>
      <link>http://crunchlife.com/articles/2009/08/25/subversion-merging-a-branch-into-trunk#comment-38767</link>
    </item>
    <item>
      <title>"Subversion: Merging a Branch into Trunk" by Joel</title>
      <description>Looks like this is only good if the trunk hasn't changed since you created the branch. If the is not the case, recent changes to the trunk will be reverted!</description>
      <pubDate>Sun, 21 Feb 2010 06:28:43 -0800</pubDate>
      <guid isPermaLink="false">urn:uuid:6da190a7-a4ec-4435-81d7-f466aaada9f9</guid>
      <link>http://crunchlife.com/articles/2009/08/25/subversion-merging-a-branch-into-trunk#comment-37392</link>
    </item>
    <item>
      <title>"Subversion: Merging a Branch into Trunk" by Abidi</title>
      <description>Once you have trunk checked out do we need to specify the trunk URL in the merge command, can we just say "svn merge svn://svnserver/project/branches/branch/project". When we merge trunk into a branch it works without specifying the target (branch) as branch is checked out?</description>
      <pubDate>Wed, 17 Feb 2010 07:51:33 -0800</pubDate>
      <guid isPermaLink="false">urn:uuid:cfd8d9af-e932-4785-8f16-c5fa9536a294</guid>
      <link>http://crunchlife.com/articles/2009/08/25/subversion-merging-a-branch-into-trunk#comment-37362</link>
    </item>
  </channel>
</rss>

