mahout-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From build...@apache.org
Subject svn commit: r911471 - in /websites/staging/mahout/trunk/content: ./ developers/github.html
Date Thu, 05 Jun 2014 18:41:15 GMT
Author: buildbot
Date: Thu Jun  5 18:41:15 2014
New Revision: 911471

Log:
Staging update by buildbot for mahout

Modified:
    websites/staging/mahout/trunk/content/   (props changed)
    websites/staging/mahout/trunk/content/developers/github.html

Propchange: websites/staging/mahout/trunk/content/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Thu Jun  5 18:41:15 2014
@@ -1 +1 @@
-1599847
+1600722

Modified: websites/staging/mahout/trunk/content/developers/github.html
==============================================================================
--- websites/staging/mahout/trunk/content/developers/github.html (original)
+++ websites/staging/mahout/trunk/content/developers/github.html Thu Jun  5 18:41:15 2014
@@ -248,7 +248,31 @@ pushing it to https://git-wip-us.apache.
 <p>Otherwise, here's recommended procedure to resolve external github pull requests
to apache/Mahout repository.</p>
 <h2 id="how-to-create-a-pr-for-contributors">How to create a PR (for contributors)</h2>
 <p>Create pull requests: [<a href="https://help.github.com/articles/creating-a-pull-request">1</a>].
</p>
-<p>Pull requests are made to apache/mahout repository on Github. </p>
+<p>Pull requests are made to apache/mahout repository on Github. In the Github UI you
should pick the master branch to target the PR. This will be reviewed and commented on so
the merge is not automatic. This can be used for discussing a contributions in progress but
the committer should make sure to state that it is not intended for merging with master in
the comments.</p>
+<h2 id="git-setup-for-committers">Git setup for Committers</h2>
+<p>You will want to fork github's apache/mahout to your own account, this will allow
Pull Requests of your own. Cloning this fork locally will set up "origin" to point to your
remote fork on github as the default remote. So if you perform "git push origin master" it
will go to github.</p>
+<p>To attach to the apache git repo do the following:</p>
+<div class="codehilite"><pre><span class="n">git</span> <span
class="n">remote</span> <span class="n">add</span> <span class="n">apache</span>
<span class="n">https</span><span class="p">:</span><span class="o">//</span><span
class="n">git</span><span class="o">-</span><span class="n">wip</span><span
class="o">-</span><span class="n">us</span><span class="p">.</span><span
class="n">apache</span><span class="p">.</span><span class="n">org</span><span
class="o">/</span><span class="n">repos</span><span class="o">/</span><span
class="n">asf</span><span class="o">/</span><span class="n">mahout</span><span
class="p">.</span><span class="n">git</span>
+</pre></div>
+
+
+<p>Now if you want to experiment with a branch do the following:</p>
+<div class="codehilite"><pre><span class="n">git</span> <span
class="n">checkout</span> <span class="o">-</span><span class="n">b</span>
<span class="n">mahout</span><span class="o">-</span><span class="n">xxxx</span>
#<span class="n">xxxx</span> <span class="n">typically</span> <span
class="n">is</span> <span class="n">a</span> <span class="n">Jira</span>
<span class="n">ticket</span> <span class="n">number</span>
+#<span class="n">do</span> <span class="n">some</span> <span class="n">work</span>
<span class="n">on</span> <span class="n">the</span> <span class="n">branch</span>
+<span class="n">git</span> <span class="n">commit</span> <span
class="o">-</span><span class="n">a</span> <span class="o">-</span><span
class="n">m</span> &quot;<span class="n">MAHOUT</span><span class="o">-</span><span
class="n">XXXX</span> <span class="n">doing</span> <span class="n">some</span>
<span class="n">work</span>&quot;
+<span class="n">git</span> <span class="n">push</span> <span class="n">origin</span>
<span class="n">mahout</span><span class="o">-</span><span class="n">xxxx</span>
#<span class="n">notice</span> <span class="n">pushing</span> <span
class="n">to</span> <span class="s">&#39;origin&#39;</span> <span
class="n">not</span> <span class="s">&#39;apache&#39;</span>
+</pre></div>
+
+
+<p>Once you are ready to commit to the apache master you can push them directly <strong>if
they are very small changes</strong>. Do the following:</p>
+<div class="codehilite"><pre><span class="n">git</span> <span
class="n">checkout</span> <span class="n">master</span>
+<span class="n">git</span> <span class="n">merge</span> <span
class="n">mahout</span><span class="o">-</span><span class="n">xxxx</span>
+# <span class="n">check</span> <span class="n">build</span> <span
class="n">and</span> <span class="n">tests</span>
+<span class="n">git</span> <span class="n">push</span> <span class="n">apache</span>
<span class="n">master</span> #<span class="n">this</span> <span
class="n">pushes</span> <span class="n">all</span> <span class="n">changes</span>
<span class="n">you</span> <span class="n">just</span> <span class="n">merged</span>
+</pre></div>
+
+
+<p>For most non-trivial work it's best to use a PR so go to your github account, pick
the branch you want to push and create a pull request. Github will ask for the "base fork:"
this should be github's apache/mahout , and the "base:" should be "master". This will create
a pull request for review on gtihub. Once the review is complete proceed to merging below.</p>
 <h2 id="merging-a-pr-and-closing-it-for-committers">Merging a PR and closing it (for
committers)</h2>
 <p>Start with reading [<a href="https://help.github.com/articles/merging-a-pull-request#merging-locally">2</a>]
(merging locally). </p>
 <p>Remember that pull requests are equivalent to a remote github branch with potentially
a multitude of commits. 
@@ -262,19 +286,26 @@ same time, it is recommended to use <str
 </pre></div>
 
 
-<p>In this example we assume that contributor Github handle is "cuser" and the PR branch
name is "cbranch" there. </p>
-<p>We also assume that <em>apache</em> remote is configured as </p>
-<div class="codehilite"><pre><span class="n">apache</span>  <span
class="n">https</span><span class="p">:</span><span class="o">//</span><span
class="n">git</span><span class="o">-</span><span class="n">wip</span><span
class="o">-</span><span class="n">us</span><span class="p">.</span><span
class="n">apache</span><span class="p">.</span><span class="n">org</span><span
class="o">/</span><span class="n">repos</span><span class="o">/</span><span
class="n">asf</span><span class="o">/</span><span class="n">mahout</span><span
class="p">.</span><span class="n">git</span> <span class="p">(</span><span
class="n">fetch</span><span class="p">)</span>
-<span class="n">apache</span>  <span class="n">https</span><span
class="p">:</span><span class="o">//</span><span class="n">git</span><span
class="o">-</span><span class="n">wip</span><span class="o">-</span><span
class="n">us</span><span class="p">.</span><span class="n">apache</span><span
class="p">.</span><span class="n">org</span><span class="o">/</span><span
class="n">repos</span><span class="o">/</span><span class="n">asf</span><span
class="o">/</span><span class="n">mahout</span><span class="p">.</span><span
class="n">git</span> <span class="p">(</span><span class="n">push</span><span
class="p">)</span>
+<p>Squash pull ensures all PR history is squashed into single commit, and allows committer
to use his/her own
+message. Read git help for merge or pull for more information about <code>--squash</code>
option.</p>
+<p>In this example we assume that the contributor's or committer's Github handle is
"cuser" and the PR branch name is "cbranch" there. </p>
+<p>We also assume that <em>apache</em> remote is configured as stated above.
To check do the following</p>
+<div class="codehilite"><pre><span class="n">git</span> <span
class="n">remote</span> <span class="o">-</span><span class="n">v</span>
 </pre></div>
 
 
-<p>Squash pull ensures all PR history is squashed into single commit, and allows committer
to use his/her own
-message. Read git help for merge or pull for more information about <code>--squash</code>
option.</p>
-<p>Next, resolve conflicts, if any, or ask contributor to rebase on top of master,
if PR went out of sync.</p>
+<p>you should see something like this:</p>
+<div class="codehilite"><pre><span class="n">origin</span>    <span
class="n">https</span><span class="p">:</span><span class="o">//</span><span
class="n">github</span><span class="p">.</span><span class="n">com</span><span
class="o">/</span><span class="n">cuser</span><span class="o">/</span><span
class="n">mahout</span><span class="p">.</span><span class="n">git</span>
<span class="p">(</span><span class="n">fetch</span><span class="p">)</span>
+<span class="n">origin</span>    <span class="n">https</span><span
class="p">:</span><span class="o">//</span><span class="n">github</span><span
class="p">.</span><span class="n">com</span><span class="o">/</span><span
class="n">cuser</span><span class="o">/</span><span class="n">mahout</span><span
class="p">.</span><span class="n">git</span> <span class="p">(</span><span
class="n">push</span><span class="p">)</span>
+<span class="n">apache</span>    <span class="n">https</span><span
class="p">:</span><span class="o">//</span><span class="n">git</span><span
class="o">-</span><span class="n">wip</span><span class="o">-</span><span
class="n">us</span><span class="p">.</span><span class="n">apache</span><span
class="p">.</span><span class="n">org</span><span class="o">/</span><span
class="n">repos</span><span class="o">/</span><span class="n">asf</span><span
class="o">/</span><span class="n">mahout</span><span class="p">.</span><span
class="n">git</span> <span class="p">(</span><span class="n">fetch</span><span
class="p">)</span>
+<span class="n">apache</span>    <span class="n">https</span><span
class="p">:</span><span class="o">//</span><span class="n">git</span><span
class="o">-</span><span class="n">wip</span><span class="o">-</span><span
class="n">us</span><span class="p">.</span><span class="n">apache</span><span
class="p">.</span><span class="n">org</span><span class="o">/</span><span
class="n">repos</span><span class="o">/</span><span class="n">asf</span><span
class="o">/</span><span class="n">mahout</span><span class="p">.</span><span
class="n">git</span> <span class="p">(</span><span class="n">push</span><span
class="p">)</span>
+</pre></div>
+
+
+<p>Next, resolve conflicts, if any, or ask a contributor to rebase on top of master,
if PR went out of sync.</p>
 <p>Also run regular patch checks and change CHANGELOG.</p>
 <p>Suppose everything is fine, you now can commit the squashed request along the lines</p>
-<div class="codehilite"><pre><span class="n">git</span> <span
class="n">commit</span> <span class="o">-</span><span class="n">a</span>
<span class="o">-</span><span class="n">m</span> &quot;<span
class="n">MAHOUT</span><span class="o">-</span><span class="n">YYYY</span>
<span class="n">description</span> <span class="p">(</span><span
class="n">cuser</span> <span class="n">via</span> <span class="n">ssc</span><span
class="p">)</span> <span class="n">closes</span> <span class="n">apache</span><span
class="o">/</span><span class="n">mahout</span>#<span class="n">ZZ</span>&quot;
+<div class="codehilite"><pre><span class="n">git</span> <span
class="n">commit</span> <span class="o">-</span><span class="n">a</span>
<span class="o">-</span><span class="n">m</span> &quot;<span
class="n">MAHOUT</span><span class="o">-</span><span class="n">YYYY</span>
<span class="n">description</span> <span class="p">(</span><span
class="n">cuser</span> <span class="n">via</span> <span class="n">your</span><span
class="o">-</span><span class="n">apache</span><span class="o">-</span><span
class="n">id</span><span class="p">)</span> <span class="n">closes</span>
<span class="n">apache</span><span class="o">/</span><span class="n">mahout</span>#<span
class="n">ZZ</span>&quot;
 </pre></div>
 
 
@@ -286,6 +317,11 @@ will close PR automatically. More inform
 
 
 <p>(this will require Apache handle credentials).</p>
+<p>The PR, once pushed, will get mirrored to github. To update your github version
push there too:</p>
+<div class="codehilite"><pre><span class="n">push</span> <span
class="n">origin</span> <span class="n">master</span>
+</pre></div>
+
+
 <p><em>Note on squashing: Since squash discards remote branch history, repeated
PRs from the same remote branch are 
 difficult for merging. The workflow implies that every new PR starts with a new rebased branch.
This is more 
 important for contributors to know, rather than for committers, because if new PR is not
mergeable, github



Mime
View raw message