Skip to content

Commit 4f4fa9c

Browse files
committed
Merge branch 'maint'
* maint: git-rerere.txt: grammatical fixups and cleanups
2 parents 08ba248 + 50a991e commit 4f4fa9c

File tree

1 file changed

+32
-33
lines changed

1 file changed

+32
-33
lines changed

Documentation/git-rerere.txt

Lines changed: 32 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,15 @@ SYNOPSIS
1212
DESCRIPTION
1313
-----------
1414

15-
In a workflow that employs relatively long lived topic branches,
16-
the developer sometimes needs to resolve the same conflict over
15+
In a workflow employing relatively long lived topic branches,
16+
the developer sometimes needs to resolve the same conflicts over
1717
and over again until the topic branches are done (either merged
1818
to the "release" branch, or sent out and accepted upstream).
1919

20-
This command helps this process by recording conflicted
21-
automerge results and corresponding hand-resolve results on the
22-
initial manual merge, and later by noticing the same automerge
23-
results and applying the previously recorded hand resolution.
20+
This command assists the developer in this process by recording
21+
conflicted automerge results and corresponding hand resolve results
22+
on the initial manual merge, and applying previously recorded
23+
hand resolutions to their corresponding automerge results.
2424

2525
[NOTE]
2626
You need to set the configuration variable rerere.enabled to
@@ -54,18 +54,18 @@ for resolutions.
5454

5555
'gc'::
5656

57-
This command is used to prune records of conflicted merge that
58-
occurred long time ago. By default, conflicts older than 15
59-
days that you have not recorded their resolution, and conflicts
60-
older than 60 days, are pruned. These are controlled with
57+
This prunes records of conflicted merges that
58+
occurred a long time ago. By default, unresolved conflicts older
59+
than 15 days and resolved conflicts older than 60
60+
days are pruned. These defaults are controlled via the
6161
`gc.rerereunresolved` and `gc.rerereresolved` configuration
62-
variables.
62+
variables respectively.
6363

6464

6565
DISCUSSION
6666
----------
6767

68-
When your topic branch modifies overlapping area that your
68+
When your topic branch modifies an overlapping area that your
6969
master branch (or upstream) touched since your topic branch
7070
forked from it, you may want to test it with the latest master,
7171
even before your topic branch is ready to be pushed upstream:
@@ -140,43 +140,42 @@ top of the tip before the test merge:
140140
This would leave only one merge commit when your topic branch is
141141
finally ready and merged into the master branch. This merge
142142
would require you to resolve the conflict, introduced by the
143-
commits marked with `*`. However, often this conflict is the
143+
commits marked with `*`. However, this conflict is often the
144144
same conflict you resolved when you created the test merge you
145-
blew away. 'git-rerere' command helps you to resolve this final
145+
blew away. 'git-rerere' helps you resolve this final
146146
conflicted merge using the information from your earlier hand
147147
resolve.
148148

149149
Running the 'git-rerere' command immediately after a conflicted
150150
automerge records the conflicted working tree files, with the
151151
usual conflict markers `<<<<<<<`, `=======`, and `>>>>>>>` in
152152
them. Later, after you are done resolving the conflicts,
153-
running 'git-rerere' again records the resolved state of these
153+
running 'git-rerere' again will record the resolved state of these
154154
files. Suppose you did this when you created the test merge of
155155
master into the topic branch.
156156

157-
Next time, running 'git-rerere' after seeing a conflicted
158-
automerge, if the conflict is the same as the earlier one
159-
recorded, it is noticed and a three-way merge between the
157+
Next time, after seeing the same conflicted automerge,
158+
running 'git-rerere' will perform a three-way merge between the
160159
earlier conflicted automerge, the earlier manual resolution, and
161-
the current conflicted automerge is performed by the command.
160+
the current conflicted automerge.
162161
If this three-way merge resolves cleanly, the result is written
163-
out to your working tree file, so you would not have to manually
162+
out to your working tree file, so you do not have to manually
164163
resolve it. Note that 'git-rerere' leaves the index file alone,
165164
so you still need to do the final sanity checks with `git diff`
166165
(or `git diff -c`) and 'git-add' when you are satisfied.
167166

168167
As a convenience measure, 'git-merge' automatically invokes
169-
'git-rerere' when it exits with a failed automerge, which
170-
records it if it is a new conflict, or reuses the earlier hand
168+
'git-rerere' upon exiting with a failed automerge and 'git-rerere'
169+
records the hand resolve when it is a new conflict, or reuses the earlier hand
171170
resolve when it is not. 'git-commit' also invokes 'git-rerere'
172-
when recording a merge result. What this means is that you do
173-
not have to do anything special yourself (Note: you still have
174-
to set the config variable rerere.enabled to enable this command).
171+
when committing a merge result. What this means is that you do
172+
not have to do anything special yourself (besides enabling
173+
the rerere.enabled config variable).
175174

176-
In our example, when you did the test merge, the manual
175+
In our example, when you do the test merge, the manual
177176
resolution is recorded, and it will be reused when you do the
178-
actual merge later with updated master and topic branch, as long
179-
as the earlier resolution is still applicable.
177+
actual merge later with the updated master and topic branch, as long
178+
as the recorded resolution is still applicable.
180179

181180
The information 'git-rerere' records is also used when running
182181
'git-rebase'. After blowing away the test merge and continuing
@@ -194,11 +193,11 @@ development on the topic branch:
194193
o---o---o---*---o---o---o---o master
195194
------------
196195

197-
you could run `git rebase master topic`, to keep yourself
198-
up-to-date even before your topic is ready to be sent upstream.
199-
This would result in falling back to three-way merge, and it
200-
would conflict the same way the test merge you resolved earlier.
201-
'git-rerere' is run by 'git-rebase' to help you resolve this
196+
you could run `git rebase master topic`, to bring yourself
197+
up-to-date before your topic is ready to be sent upstream.
198+
This would result in falling back to a three-way merge, and it
199+
would conflict the same way as the test merge you resolved earlier.
200+
'git-rerere' will be run by 'git-rebase' to help you resolve this
202201
conflict.
203202

204203

0 commit comments

Comments
 (0)