@matheusbsbs / matheus-bagliano / commits / bb73d73c08
Fork 0

Refactor merge strategies into separate includable file.

Signed-off-by: Jon Loeliger <jdl@freescale.com> Signed-off-by: Junio C Hamano <junkio@cox.net>

Jon Loeliger committed Nov 6, 2005 at 10:26 UTC bb73d73c0885fce357e0d70aa51c2215a8e38a4e
3 files changed +38 -35
Documentation/git-merge.txt
+2
@@ -34,6 +34,8 @@ include::merge-pull-opts.txt[]
34 least one <remote>. Specifying more than one <remote>
35 obviously means you are trying an Octopus.
36
37 +include::merge-strategies.txt[]
38 +
39
40 SEE ALSO
41 --------
Documentation/git-pull.txt
+1 -35
@@ -31,42 +31,8 @@ include::pull-fetch-param.txt[]
31
32 include::merge-pull-opts.txt[]
33
34 +include::merge-strategies.txt[]
35
35 -MERGE STRATEGIES
36 -----------------
37 -
38 -resolve::
39 - This can only resolve two heads (i.e. the current branch
40 - and another branch you pulled from) using 3-way merge
41 - algorithm. It tries to carefully detect criss-cross
42 - merge ambiguities and is considered generally safe and
43 - fast. This is the default merge strategy when pulling
44 - one branch.
45 -
46 -recursive::
47 - This can only resolve two heads using 3-way merge
48 - algorithm. When there are more than one common
49 - ancestors that can be used for 3-way merge, it creates a
50 - merged tree of the common ancestores and uses that as
51 - the reference tree for the 3-way merge. This has been
52 - reported to result in fewer merge conflicts without
53 - causing mis-merges by tests done on actual merge commits
54 - taken from Linux 2.6 kernel development history.
55 - Additionally this can detect and handle merges involving
56 - renames.
57 -
58 -octopus::
59 - This resolves more than two-head case, but refuses to do
60 - complex merge that needs manual resolution. It is
61 - primarily meant to be used for bundling topic branch
62 - heads together. This is the default merge strategy when
63 - pulling more than one branch.
64 -
65 -ours::
66 - This resolves any number of heads, but the result of the
67 - merge is always the current branch head. It is meant to
68 - be used to supersede old development history of side
69 - branches.
36
37
38 EXAMPLES
Documentation/merge-strategies.txt new
+35
@@ -0,0 +1,35 @@
1 +MERGE STRATEGIES
2 +----------------
3 +
4 +resolve::
5 + This can only resolve two heads (i.e. the current branch
6 + and another branch you pulled from) using 3-way merge
7 + algorithm. It tries to carefully detect criss-cross
8 + merge ambiguities and is considered generally safe and
9 + fast. This is the default merge strategy when pulling
10 + one branch.
11 +
12 +recursive::
13 + This can only resolve two heads using 3-way merge
14 + algorithm. When there are more than one common
15 + ancestors that can be used for 3-way merge, it creates a
16 + merged tree of the common ancestores and uses that as
17 + the reference tree for the 3-way merge. This has been
18 + reported to result in fewer merge conflicts without
19 + causing mis-merges by tests done on actual merge commits
20 + taken from Linux 2.6 kernel development history.
21 + Additionally this can detect and handle merges involving
22 + renames.
23 +
24 +octopus::
25 + This resolves more than two-head case, but refuses to do
26 + complex merge that needs manual resolution. It is
27 + primarily meant to be used for bundling topic branch
28 + heads together. This is the default merge strategy when
29 + pulling more than one branch.
30 +
31 +ours::
32 + This resolves any number of heads, but the result of the
33 + merge is always the current branch head. It is meant to
34 + be used to supersede old development history of side
35 + branches.