@@ -20,20 +20,20 @@ DESCRIPTION
2020-----------
2121Incorporates changes from the named commits (since the time their
2222histories diverged from the current branch) into the current
23- branch. This command is used by ' git pull' to incorporate changes
23+ branch. This command is used by ` git pull` to incorporate changes
2424from another repository and can be used by hand to merge changes
2525from one branch into another.
2626
2727Assume the following history exists and the current branch is
28- " `master`" :
28+ `master`:
2929
3030------------
3131 A---B---C topic
3232 /
3333 D---E---F---G master
3434------------
3535
36- Then " `git merge topic`" will replay the changes made on the
36+ Then `git merge topic` will replay the changes made on the
3737`topic` branch since it diverged from `master` (i.e., `E`) until
3838its current commit (`C`) on top of `master`, and record the result
3939in a new commit along with the names of the two parent commits and
@@ -46,21 +46,21 @@ a log message from the user describing the changes. Before the operation,
4646 D---E---F---G---H master
4747------------
4848
49- The second syntax ("`git merge --abort`") can only be run after the
50- merge has resulted in conflicts. 'git merge --abort' will abort the
51- merge process and try to reconstruct the pre-merge state. However,
52- if there were uncommitted changes when the merge started (and
53- especially if those changes were further modified after the merge
54- was started), 'git merge --abort' will in some cases be unable to
55- reconstruct the original (pre-merge) changes. Therefore:
49+ A merge stops if there's a conflict that cannot be resolved
50+ automatically or if `--no-commit` was provided when initiating the
51+ merge. At that point you can run `git merge --abort` or `git merge
52+ --continue`.
5653
57- *Warning*: Running 'git merge' with non-trivial uncommitted changes is
54+ `git merge --abort` will abort the merge process and try to reconstruct
55+ the pre-merge state. However, if there were uncommitted changes when the
56+ merge started (and especially if those changes were further modified
57+ after the merge was started), `git merge --abort` will in some cases be
58+ unable to reconstruct the original (pre-merge) changes. Therefore:
59+
60+ *Warning*: Running `git merge` with non-trivial uncommitted changes is
5861discouraged: while possible, it may leave you in a state that is hard to
5962back out of in the case of a conflict.
6063
61- The third syntax ("`git merge --continue`") can only be run after the
62- merge has resulted in conflicts.
63-
6464OPTIONS
6565-------
6666:git-merge: 1
@@ -74,8 +74,8 @@ include::merge-options.txt[]
7474If `--log` is specified, a shortlog of the commits being merged
7575will be appended to the specified message.
7676+
77- The ' git fmt-merge-msg' command can be
78- used to give a good default for automated ' git merge'
77+ The ` git fmt-merge-msg` command can be
78+ used to give a good default for automated ` git merge`
7979invocations. The automated message can include the branch description.
8080
8181--into-name <branch>::
@@ -104,14 +104,14 @@ include::rerere-options.txt[]
104104 present, apply it to the worktree.
105105+
106106If there were uncommitted worktree changes present when the merge
107- started, ' git merge --abort' will in some cases be unable to
107+ started, ` git merge --abort` will in some cases be unable to
108108reconstruct these changes. It is therefore recommended to always
109- commit or stash your changes before running ' git merge' .
109+ commit or stash your changes before running ` git merge` .
110110+
111- ' git merge --abort' is equivalent to ' git reset --merge' when
111+ ` git merge --abort` is equivalent to ` git reset --merge` when
112112`MERGE_HEAD` is present unless `MERGE_AUTOSTASH` is also present in
113- which case ' git merge --abort' applies the stash entry to the worktree
114- whereas ' git reset --merge' will save the stashed changes in the stash
113+ which case ` git merge --abort` applies the stash entry to the worktree
114+ whereas ` git reset --merge` will save the stashed changes in the stash
115115list.
116116
117117--quit::
@@ -120,8 +120,8 @@ list.
120120 stash entry will be saved to the stash list.
121121
122122--continue::
123- After a ' git merge' stops due to conflicts you can conclude the
124- merge by running ' git merge --continue' (see "HOW TO RESOLVE
123+ After a ` git merge` stops due to conflicts you can conclude the
124+ merge by running ` git merge --continue` (see "HOW TO RESOLVE
125125 CONFLICTS" section below).
126126
127127<commit>...::
@@ -144,25 +144,25 @@ PRE-MERGE CHECKS
144144Before applying outside changes, you should get your own work in
145145good shape and committed locally, so it will not be clobbered if
146146there are conflicts. See also linkgit:git-stash[1].
147- ' git pull' and ' git merge' will stop without doing anything when
148- local uncommitted changes overlap with files that ' git pull'/' git
149- merge' may need to update.
147+ ` git pull` and ` git merge` will stop without doing anything when
148+ local uncommitted changes overlap with files that ` git pull`/` git
149+ merge` may need to update.
150150
151151To avoid recording unrelated changes in the merge commit,
152- ' git pull' and ' git merge' will also abort if there are any changes
152+ ` git pull` and ` git merge` will also abort if there are any changes
153153registered in the index relative to the `HEAD` commit. (Special
154154narrow exceptions to this rule may exist depending on which merge
155155strategy is in use, but generally, the index must match HEAD.)
156156
157- If all named commits are already ancestors of `HEAD`, ' git merge'
157+ If all named commits are already ancestors of `HEAD`, ` git merge`
158158will exit early with the message "Already up to date."
159159
160160FAST-FORWARD MERGE
161161------------------
162162
163163Often the current branch head is an ancestor of the named commit.
164- This is the most common case especially when invoked from ' git
165- pull' : you are tracking an upstream repository, you have committed
164+ This is the most common case especially when invoked from ` git
165+ pull` : you are tracking an upstream repository, you have committed
166166no local changes, and now you want to update to a newer upstream
167167revision. In this case, a new commit is not needed to store the
168168combined history; instead, the `HEAD` (along with the index) is
@@ -269,7 +269,7 @@ Barbie's remark on your side. The only thing you can tell is that your
269269side wants to say it is hard and you'd prefer to go shopping, while the
270270other side wants to claim it is easy.
271271
272- An alternative style can be used by setting the " merge.conflictStyle"
272+ An alternative style can be used by setting the ` merge.conflictStyle`
273273configuration variable to either "diff3" or "zdiff3". In "diff3"
274274style, the above conflict may look like this:
275275
@@ -328,10 +328,10 @@ After seeing a conflict, you can do two things:
328328
329329 * Resolve the conflicts. Git will mark the conflicts in
330330 the working tree. Edit the files into shape and
331- ' git add' them to the index. Use ' git commit' or
332- ' git merge --continue' to seal the deal. The latter command
331+ ` git add` them to the index. Use ` git commit` or
332+ ` git merge --continue` to seal the deal. The latter command
333333 checks whether there is a (interrupted) merge in progress
334- before calling ' git commit' .
334+ before calling ` git commit` .
335335
336336You can work through the conflict with a number of tools:
337337
@@ -392,7 +392,7 @@ CONFIGURATION
392392
393393branch.<name>.mergeOptions::
394394 Sets default options for merging into branch <name>. The syntax and
395- supported options are the same as those of ' git merge' , but option
395+ supported options are the same as those of ` git merge` , but option
396396 values containing whitespace characters are currently not supported.
397397
398398include::includes/cmd-config-section-rest.txt[]
0 commit comments