You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2015/07/10 14:46:42 UTC

[06/12] isis git commit: ISIS-1052: docs for github-pr.sh

ISIS-1052: docs for github-pr.sh


Project: http://git-wip-us.apache.org/repos/asf/isis/repo
Commit: http://git-wip-us.apache.org/repos/asf/isis/commit/a11b07ff
Tree: http://git-wip-us.apache.org/repos/asf/isis/tree/a11b07ff
Diff: http://git-wip-us.apache.org/repos/asf/isis/diff/a11b07ff

Branch: refs/heads/master
Commit: a11b07ff861ff7a7bf6c18f8da03afb149eae337
Parents: bd53cd8
Author: Dan Haywood <da...@haywood-associates.co.uk>
Authored: Fri Jul 10 13:00:46 2015 +0100
Committer: Dan Haywood <da...@haywood-associates.co.uk>
Committed: Fri Jul 10 13:00:46 2015 +0100

----------------------------------------------------------------------
 .../main/asciidoc/guides/_cg_committers.adoc    |  1 +
 .../_cg_committers_merging-a-pull-request.adoc  | 76 ++++++++++++++++++++
 2 files changed, 77 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/isis/blob/a11b07ff/adocs/documentation/src/main/asciidoc/guides/_cg_committers.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/_cg_committers.adoc b/adocs/documentation/src/main/asciidoc/guides/_cg_committers.adoc
index 0eb5938..f82d5fe 100644
--- a/adocs/documentation/src/main/asciidoc/guides/_cg_committers.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/_cg_committers.adoc
@@ -12,6 +12,7 @@ This chapter provides guidance for Apache Isis' own committers.
 // for some reason this doesn't seem to include:: correctly; that said, it's incomplete anyway
 //include::_cg_committers_applying-patches.adoc[leveloffset=+1]
 
+include::_cg_committers_merging-a-pull-request.adoc[leveloffset=+1]
 include::_cg_committers_recreating-an-archetype.adoc[leveloffset=+1]
 include::_cg_committers_cutting-a-release.adoc[leveloffset=+1]
 include::_cg_committers_cutting-a-release-one-pager.adoc[leveloffset=+1]

http://git-wip-us.apache.org/repos/asf/isis/blob/a11b07ff/adocs/documentation/src/main/asciidoc/guides/_cg_committers_merging-a-pull-request.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/_cg_committers_merging-a-pull-request.adoc b/adocs/documentation/src/main/asciidoc/guides/_cg_committers_merging-a-pull-request.adoc
new file mode 100644
index 0000000..4a92748
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/guides/_cg_committers_merging-a-pull-request.adoc
@@ -0,0 +1,76 @@
+[[_cg_committers_merging-a-pull-request]]
+= Merging a Pull Request
+: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. http://www.apache.org/licenses/license-2.0 . unless required by applicable law or agreed to in writing, software distributed under the license is distributed on an "as is" basis, without warranties or  conditions of any kind, either express or implied. see the license for the specific language governing permissions and limitations under the license.
+:_basedir: ../
+:_imagesdir: images/
+:toc: right
+
+
+The process for merging in github pull requests (so that they can be tested locally before committing) has been scripted in the `github-pr.sh` script.
+
+The script will merge the fork into a temporary branch, and then run a build.  Once you are happy, you can commit.
+
+The overall process is as follows:
+
+* locate/raise JIRA ticket, eg ISIS-1162
+* checkout branch from which PR was forked (usually just 'master')
+* merge PR into temporary branch using the `github-pr.sh` script
+* test the change locally (run the app, rebuild, manual regression tests etc)
+* merge temporary branch into mainline, and commit
+
+
+For example:
+
+[source,bash]
+----
+github-pr.sh isis 1162 31
+----
+
+where
+* `isis` is the JIRA project and repo
+* `1162` is the JIRA ticket number
+* `31`   is the gthub PR issue number
+
+
+== Prerequisites
+
+The script uses 'jq' to parse JSON.  To install:
+
+* on Linux: +
++
+[source,bash]
+----
+aptitude install jq
+----
+
+* on MacOS: +
++
+[source,bash]
+----
+brew install jq
+----
+
+* on Windows: +
++
+Download exe from http://stedolan.github.io/jq/download/[website]
+
+
+== Example transcript
+
+[source,bash]
+----
+
+...
+Checkout out local branch - master ...
+Switched to branch 'master'
+Your branch is ahead of 'estatio/master' by 2 commits.
+  (use "git push" to publish your local commits)
+
+If build successful and happy to merge, execute:
+
+git merge --ff-only ISIS-1162_pr-31 && git push origin master && git branch -d ISIS-1162_pr-31
+----
+
+
+
+