path: root/Documentation
diff options
authorElijah Newren <>2021-07-22 05:04:48 (GMT)
committerJunio C Hamano <>2021-07-22 18:54:29 (GMT)
commit031e2f7ae195069d00d21cde906fce5b0318dbdd (patch)
tree61c6b5cb09f65ab91fe17c72c7cdfc5d8213c5f0 /Documentation
parentadc27d6a9374d012b091bc348c20f5bfdbee52d1 (diff)
pull: abort by default when fast-forwarding is not possible
We have for some time shown a long warning when the user does not specify how to reconcile divergent branches with git pull. Make it an error now. Initial-patch-by: Alex Henrie <> Signed-off-by: Elijah Newren <> Signed-off-by: Junio C Hamano <>
Diffstat (limited to 'Documentation')
1 files changed, 12 insertions, 8 deletions
diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt
index 5c3fb67..cad3f6b 100644
--- a/Documentation/git-pull.txt
+++ b/Documentation/git-pull.txt
@@ -15,14 +15,18 @@ SYNOPSIS
-Incorporates changes from a remote repository into the current
-branch. In its default mode, `git pull` is shorthand for
-`git fetch` followed by `git merge FETCH_HEAD`.
-More precisely, 'git pull' runs 'git fetch' with the given
-parameters and calls 'git merge' to merge the retrieved branch
-heads into the current branch.
-With `--rebase`, it runs 'git rebase' instead of 'git merge'.
+Incorporates changes from a remote repository into the current branch.
+If the current branch is behind the remote, then by default it will
+fast-forward the current branch to match the remote. If the current
+branch and the remote have diverged, the user needs to specify how to
+reconcile the divergent branches with `--no-ff`, `--ff`, or `--rebase`
+(or the corresponding configuration options in `pull.ff` or
+More precisely, `git pull` runs `git fetch` with the given parameters
+and then depending on configuration options or command line flags,
+will call either `git merge` or `git rebase` to reconcile diverging
<repository> should be the name of a remote repository as
passed to linkgit:git-fetch[1]. <refspec> can name an