From 82e481ebd9156d904845638539e08282c7995bb5 Mon Sep 17 00:00:00 2001 From: "Alexandre M. Reis" Date: Mon, 3 Jul 2017 15:28:29 +0200 Subject: [PATCH 1/2] Include git merge --no-ff in best practices --- common-flow.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/common-flow.md b/common-flow.md index 6c25191..45ee227 100644 --- a/common-flow.md +++ b/common-flow.md @@ -93,6 +93,10 @@ interpreted as described in [RFC 2119](https://tools.ietf.org/html/rfc2119). 4. It is RECOMMENDED that you always do "git pull --rebase" instead of "git pull" to avoid unnecessary merge commits. You can make this the default behavior of "git pull" with "git config --global pull.rebase true". +    5. It is RECOMMENDED that all branches be merged using "git merge --no-ff". + This makes sure the reference to the original branch is kept in the commits, + allows one to revert a merge by reverting a single merge commit, and creates + a merge commit to mark the integration of the branch with master. 4. Versioning 1. The project MUST have its version hard-coded somewhere in the code-base. It is RECOMMENDED that this is done in a file called "VERSION" From abc2d4350f58d5011886447efdd3ff450cf7a14a Mon Sep 17 00:00:00 2001 From: "Alexandre M. Reis" Date: Mon, 3 Jul 2017 15:36:09 +0200 Subject: [PATCH 2/2] Update common-flow.md --- common-flow.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common-flow.md b/common-flow.md index 45ee227..0d0694b 100644 --- a/common-flow.md +++ b/common-flow.md @@ -93,7 +93,7 @@ interpreted as described in [RFC 2119](https://tools.ietf.org/html/rfc2119). 4. It is RECOMMENDED that you always do "git pull --rebase" instead of "git pull" to avoid unnecessary merge commits. You can make this the default behavior of "git pull" with "git config --global pull.rebase true". -    5. It is RECOMMENDED that all branches be merged using "git merge --no-ff". + 5. It is RECOMMENDED that all branches be merged using "git merge --no-ff". This makes sure the reference to the original branch is kept in the commits, allows one to revert a merge by reverting a single merge commit, and creates a merge commit to mark the integration of the branch with master.