mahout-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject svn commit: r1597886 - /mahout/site/mahout_cms/trunk/content/developers/
Date Tue, 27 May 2014 22:01:15 GMT
Author: dlyubimov
Date: Tue May 27 22:01:14 2014
New Revision: 1597886

CMS commit to mahout by dlyubimov


Added: mahout/site/mahout_cms/trunk/content/developers/
--- mahout/site/mahout_cms/trunk/content/developers/ (added)
+++ mahout/site/mahout_cms/trunk/content/developers/ Tue May 27 22:01:14 2014
@@ -0,0 +1,92 @@
+Notice:    Licensed to the Apache Software Foundation (ASF) under one
+           or more contributor license agreements.  See the NOTICE file
+           distributed with this work for additional information
+           regarding copyright ownership.  The ASF licenses this file
+           to you under the Apache License, Version 2.0 (the
+           "License"); you may not use this file except in compliance
+           with the License.  You may obtain a copy of the License at
+           .
+           .
+           Unless required by applicable law or agreed to in writing,
+           software distributed under the License is distributed on an
+           KIND, either express or implied.  See the License for the
+           specific language governing permissions and limitations
+           under the License.
+# Handling Github PRs #
+## how to create a PR (for contributers)
+Read [[1]]. 
+Pull requests are made to apache/mahout repository on Github. 
+## merging a PR and closing it (for committers). 
+Remember that pull requests are equivalent to a remote branch with potentially a multitude
of commits. 
+In this case it is recommended to squash remote commit history to have one commit per issue,
+than merging in a multitude of contributer's commits. In order to do that, as well as close
the PR at the 
+same time, it is recommended to use **squash commits**.
+Read [[2]] (merging locally). Merging pull requests are equivalent to merging contributor's
+    git checkout master      # switch to local master branch
+    git pull apache master   # fast-forward to current remote HEAD
+    git pull --squash cbranch  # merge to master 
+In this example we assume that contributor Github handle is "cuser" and the PR branch name
is "cbranch" there. We also 
+assume that *apache* remote is configured as 
+    apache (fetch)
+    apache (push)
+Squash pull ensures all PR history is squashed into single commit. Also, it is not yet committed,
even if 
+fast forward is possible, so you get chance to change things before committing.
+At this point resolve conflicts, if any, or ask contributor to rebase on top of master, if
PR went out of sync.
+Also run regular patch checks and change CHANGELOG.
+Suppose everything is fine, you now can commit the squashed request 
+    git commit -a
+edit message to contain "MAHOUT-YYYY description **closes #ZZ**", where ZZ is the pull request
+Including "closes #ZZ" will close PR automatically. More information [[3]].
+   push apache master
+(this will require credentials).
+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
+would warn to begin with. Anyway, watch for dupe PRs (based on same source branches). This
is a bad practice.
+## Closing a PR without committing 
+When we want to reject a PR (close without committing), just do the following commit on master's
+*without merging the PR*: 
+    git commit --allow-empty -m "closes #ZZ *Won't fix*"
+    git push apache master
+that should close PR without merging and any code modifications in the master repository.
+## Apache/github integration features 
+Read [[4]]. Issue handles mentioned in comments and PR name should post to mailing lists
and Jira.

View raw message