Skip to content

Commit e3fbb47

Browse files
committed
maintaining.scc: standardize on "--" for em dashes, add italics
Innocuous, pedantic cleanup. Signed-off-by: Robert P. J. Day <[email protected]>
1 parent 64631d8 commit e3fbb47

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

book/05-distributed-git/sections/maintaining.asc

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ Whether you maintain a canonical repository or want to help by verifying or appr
88
==== Working in Topic Branches
99

1010
(((branches, topic)))
11-
When you're thinking of integrating new work, it's generally a good idea to try it out in a topic branch – a temporary branch specifically made to try out that new work.
11+
When you're thinking of integrating new work, it's generally a good idea to try it out in a _topic branch_ -- a temporary branch specifically made to try out that new work.
1212
This way, it's easy to tweak a patch individually and leave it if it's not working until you have time to come back to it.
1313
If you create a simple branch name based on the theme of the work you're going to try, such as `ruby_client` or something similarly descriptive, you can easily remember it if you have to abandon it for a while and come back later.
14-
The maintainer of the Git project tends to namespace these branches as well such as `sc/ruby_client`, where `sc` is short for the person who contributed the work.
14+
The maintainer of the Git project tends to namespace these branches as well -- such as `sc/ruby_client`, where `sc` is short for the person who contributed the work.
1515
As you'll remember, you can create the branch based off your `master` branch like this:
1616

1717
[source,console]
@@ -51,9 +51,9 @@ It's almost identical to running a `patch -p1` command to apply the patch, altho
5151
It also handles file adds, deletes, and renames if they're described in the `git diff` format, which `patch` won't do.
5252
Finally, `git apply` is an ``apply all or abort all'' model where either everything is applied or nothing is, whereas `patch` can partially apply patchfiles, leaving your working directory in a weird state.
5353
`git apply` is overall much more conservative than `patch`.
54-
It won't create a commit for you after running it, you must stage and commit the changes introduced manually.
54+
It won't create a commit for you -- after running it, you must stage and commit the changes introduced manually.
5555

56-
You can also use `git apply` to see if a patch applies cleanly before you try actually applying it you can run `git apply --check` with the patch:
56+
You can also use `git apply` to see if a patch applies cleanly before you try actually applying it -- you can run `git apply --check` with the patch:
5757

5858
[source,console]
5959
----
@@ -137,7 +137,7 @@ To restore the original branch and stop patching run "git am --abort".
137137
----
138138

139139
This command puts conflict markers in any files it has issues with, much like a conflicted merge or rebase operation.
140-
You solve this issue much the same way edit the file to resolve the conflict, stage the new file, and then run `git am --resolved` to continue to the next patch:
140+
You solve this issue much the same way -- edit the file to resolve the conflict, stage the new file, and then run `git am --resolved` to continue to the next patch:
141141

142142
[source,console]
143143
----
@@ -149,7 +149,7 @@ Applying: seeing if this helps the gem
149149

150150
If you want Git to try a bit more intelligently to resolve the conflict, you can pass a `-3` option to it, which makes Git attempt a three-way merge.
151151
This option isn't on by default because it doesn't work if the commit the patch says it was based on isn't in your repository.
152-
If you do have that commit if the patch was based on a public commit then the `-3` option is generally much smarter about applying a conflicting patch:
152+
If you do have that commit -- if the patch was based on a public commit -- then the `-3` option is generally much smarter about applying a conflicting patch:
153153

154154
[source,console]
155155
----
@@ -201,7 +201,7 @@ If she emails you again later with another branch containing another great featu
201201
This is most useful if you're working with a person consistently.
202202
If someone only has a single patch to contribute once in a while, then accepting it over email may be less time consuming than requiring everyone to run their own server and having to continually add and remove remotes to get a few patches.
203203
You're also unlikely to want to have hundreds of remotes, each for someone who contributes only a patch or two.
204-
However, scripts and hosted services may make this easier it depends largely on how you develop and how your contributors develop.
204+
However, scripts and hosted services may make this easier -- it depends largely on how you develop and how your contributors develop.
205205

206206
The other advantage of this approach is that you get the history of the commits as well.
207207
Although you may have legitimate merge issues, you know where in your history their work is based; a proper three-way merge is the default rather than having to supply a `-3` and hope the patch was generated off a public commit to which you have access.
@@ -406,7 +406,7 @@ Now you can remove your topic branch and drop the commits you didn't want to pul
406406
(((git commands, rerere)))(((rerere)))
407407
If you're doing lots of merging and rebasing, or you're maintaining a long-lived topic branch, Git has a feature called ``rerere'' that can help.
408408

409-
Rerere stands for ``reuse recorded resolution'' it's a way of shortcutting manual conflict resolution.
409+
Rerere stands for ``reuse recorded resolution'' -- it's a way of shortcutting manual conflict resolution.
410410
When rerere is enabled, Git will keep a set of pre- and post-images from successful merges, and if it notices that there's a conflict that looks exactly like one you've already fixed, it'll just use the fix from last time, without bothering you with it.
411411

412412
This feature comes in two parts: a configuration setting and a command.

0 commit comments

Comments
 (0)