summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2013-09-11 14:57:49 -0700
committerJunio C Hamano <gitster@pobox.com>2013-09-11 14:57:49 -0700
commit6026f68652b6f220ce12c161fe8ac3e44a1b5b5a (patch)
tree80c9ed85435b42a3552d20837864111a0ac36a75 /Documentation
parent2de0f39cd27d8ab8eae2e3430b81294f26252693 (diff)
parent66713ef3b00933755cdeff1ae823dda7b5843640 (diff)
downloadgit-6026f68652b6f220ce12c161fe8ac3e44a1b5b5a.tar.gz
Merge branch 'sh/pull-rebase-preserve'
"git pull --rebase" always flattened the history; pull.rebase can now be set to "preserve" to invoke "rebase --preserve-merges". * sh/pull-rebase-preserve: pull: allow pull to preserve merges when rebasing
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/config.txt8
-rw-r--r--Documentation/git-pull.txt18
2 files changed, 20 insertions, 6 deletions
diff --git a/Documentation/config.txt b/Documentation/config.txt
index 00bde9dec5..9d101a9032 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -766,6 +766,10 @@ branch.<name>.rebase::
"git pull" is run. See "pull.rebase" for doing this in a non
branch-specific manner.
+
+ When preserve, also pass `--preserve-merges` along to 'git rebase'
+ so that locally committed merge commits will not be flattened
+ by running 'git pull'.
++
*NOTE*: this is a possibly dangerous operation; do *not* use
it unless you understand the implications (see linkgit:git-rebase[1]
for details).
@@ -1879,6 +1883,10 @@ pull.rebase::
pull" is run. See "branch.<name>.rebase" for setting this on a
per-branch basis.
+
+ When preserve, also pass `--preserve-merges` along to 'git rebase'
+ so that locally committed merge commits will not be flattened
+ by running 'git pull'.
++
*NOTE*: this is a possibly dangerous operation; do *not* use
it unless you understand the implications (see linkgit:git-rebase[1]
for details).
diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt
index 6ef8d599d3..beea10b148 100644
--- a/Documentation/git-pull.txt
+++ b/Documentation/git-pull.txt
@@ -102,12 +102,18 @@ include::merge-options.txt[]
:git-pull: 1
-r::
---rebase::
- Rebase the current branch on top of the upstream branch after
- fetching. If there is a remote-tracking branch corresponding to
- the upstream branch and the upstream branch was rebased since last
- fetched, the rebase uses that information to avoid rebasing
- non-local changes.
+--rebase[=false|true|preserve]::
+ When true, rebase the current branch on top of the upstream
+ branch after fetching. If there is a remote-tracking branch
+ corresponding to the upstream branch and the upstream branch
+ was rebased since last fetched, the rebase uses that information
+ to avoid rebasing non-local changes.
++
+When preserve, also rebase the current branch on top of the upstream
+branch, but pass `--preserve-merges` along to `git rebase` so that
+locally created merge commits will not be flattened.
++
+When false, merge the current branch into the upstream branch.
+
See `pull.rebase`, `branch.<name>.rebase` and `branch.autosetuprebase` in
linkgit:git-config[1] if you want to make `git pull` always use