Author: lukaszlenart
Date: Wed Dec 31 08:53:27 2014
New Revision: 934564

Log:
Updates production

Modified:
    websites/production/struts/content/submitting-patches.html

Modified: websites/production/struts/content/submitting-patches.html
==============================================================================
--- websites/production/struts/content/submitting-patches.html (original)
+++ websites/production/struts/content/submitting-patches.html Wed Dec 31 
08:53:27 2014
@@ -125,13 +125,15 @@
 <p>Struts uses Git and to manage the repository the git-flow was adopted, to 
read more about that please follow the links below:</p>
 
 <ul>
-<li>http://nvie.com/posts/a-successful-git-branching-model/</li>
-<li>https://github.com/nvie/gitflow</li>
+<li><a 
href="http://nvie.com/posts/a-successful-git-branching-model/";>http://nvie.com/posts/a-successful-git-branching-model/</a></li>
+<li><a 
href="https://github.com/petervanderdoes/gitflow";>https://github.com/petervanderdoes/gitflow</a></li>
 </ul>
 
-<p>First step is to install git-flow locally on your box, please follow the 
steps from this link</p>
+<p>First step is to install git-flow AVH Edition locally on your box, please 
follow the steps from this link</p>
 
-<p>https://github.com/nvie/gitflow/wiki/Installation</p>
+<ul>
+<li><a 
href="https://github.com/petervanderdoes/gitflow/wiki";>https://github.com/petervanderdoes/gitflow/wiki</a></li>
+</ul>
 
 <p>Now you can clone Struts repository locally</p>
 <div class="highlight"><pre><code class="text language-text" 
data-lang="text">git clone https://git-wip-us.apache.org/repos/asf/struts.git   
 
@@ -188,6 +190,40 @@ your fork and branch to compare the diff
 
 <p>Finally hit <code>Create Pull Request</code> button and you are done!</p>
 
+<h3>How to merge Pull Requests</h3>
+
+<p>This section is for committers only who want to merge incoming Pull 
Requests. Please remember that the repo at GitHub
+is read-only, we (committers) have limited rights to it.</p>
+
+<p>To merge PR please add GitHub as a new remote to your local copy</p>
+<div class="highlight"><pre><code class="text language-text" 
data-lang="text">git remote add github [email protected]:apache/struts.git
+</code></pre></div>
+<p>then you can fetch the PR localy and put it under a branch</p>
+<div class="highlight"><pre><code class="text language-text" 
data-lang="text">git fetch github pull/28/head:some-branch    
+</code></pre></div>
+<p>where</p>
+
+<ul>
+<li><code>github</code> is remote name</li>
+<li><code>28</code> is Pull Request id 
(https://github.com/apache/struts/pull/28)</li>
+<li><code>some-branch</code> local branch name, it can be the same as used to 
create the PR</li>
+</ul>
+
+<p>now you can switch to this branch and test, review it</p>
+<div class="highlight"><pre><code class="text language-text" 
data-lang="text">git checkout some-branch
+</code></pre></div>
+<p>after reviewing, switch back to the <code>develop</code> branch and 
merge</p>
+<div class="highlight"><pre><code class="text language-text" 
data-lang="text">git checkout develop
+git merge some-branch -m &quot;WW-XXXX Merges #28 which resolves ...&quot;
+</code></pre></div>
+<p>using <code>-m</code> you can define your own merge message, it&#39;s a 
good way to link merge commit with ticket in JIRA</p>
+<div class="highlight"><pre><code class="text language-text" 
data-lang="text">git branch -d some-branch
+</code></pre></div>
+<p>remove the branch as it isn&#39;t needed anymore</p>
+<div class="highlight"><pre><code class="text language-text" 
data-lang="text">git push
+</code></pre></div>
+<p>after pushing changes, <code>asfbot</code> will close the PR at GitHub. </p>
+
 <h2>Further reading</h2>
 
 <ul>


Reply via email to