]> git.ipfire.org Git - thirdparty/git.git/blame - Documentation/git-merge-base.txt
merge-base: teach "git merge-base" to drive underlying merge_bases_many()
[thirdparty/git.git] / Documentation / git-merge-base.txt
CommitLineData
2cf565c5
DG
1git-merge-base(1)
2=================
2cf565c5
DG
3
4NAME
5----
c3f0baac 6git-merge-base - Find as good common ancestors as possible for a merge
2cf565c5
DG
7
8
9SYNOPSIS
10--------
b1889c36 11'git merge-base' [--all] <commit> <commit>
2cf565c5
DG
12
13DESCRIPTION
14-----------
2aa83961 15
ba020ef5 16'git-merge-base' finds as good a common ancestor as possible between
483bc4f0
JN
17the two commits. That is, given two commits A and B, `git merge-base A
18B` will output a commit which is reachable from both A and B through
2aa83961
FK
19the parent relationship.
20
21Given a selection of equally good common ancestors it should not be
22relied on to decide in any particular way.
2cf565c5 23
ba020ef5 24The 'git-merge-base' algorithm is still in flux - use the source...
2cf565c5 25
2aa83961
FK
26OPTIONS
27-------
28--all::
29 Output all common ancestors for the two commits instead of
30 just one.
2cf565c5
DG
31
32Author
33------
34Written by Linus Torvalds <torvalds@osdl.org>
35
36Documentation
37--------------
38Documentation by David Greaves, Junio C Hamano and the git-list <git@vger.kernel.org>.
39
40GIT
41---
9e1f0a85 42Part of the linkgit:git[1] suite