Mercurial: The Definitive Guide

Errata for Mercurial: The Definitive Guide

Submit your own errata for this product.


The errata list is a list of errors and their corrections that were found after the product was released.

The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.


Color Key: Serious Technical Mistake Minor Technical Mistake Language or formatting error Typo Question Note Update



Version Location Description Submitted By Date Submitted
Printed Page 36
Figure 3-2

The Head changeset identifier should be "5:cbfc" not "5: b15c" Similarly for the Tip: "6:12ef" not "6:793c"

Gene Ratzlaff  Feb 18, 2014 
Printed Page 38
Figure 3-3

In figure 3-3, the tip on the right side should have the local revision 7, not 6 (both 793c and 798a are listed as "6:").

Sean A Reith  Apr 20, 2010 
Mobi Page 38
Last paragraph

(Page reference is taken from the PDF version) "file merging tool You can see a screenshot of kdiff3 in action in Figure 3-." should read "file merging tools. You can see a screenshot of kdiff3 in action in Figure 3-5." First sentence not finished correctly after third word and figure missing second digit.

Jonathan Hansford  Apr 17, 2013 
Printed Page 38
Figure 3-3

Left side: Head is 5: cbfe Tip (and head) is 6: 12ef Right side: Tip is 7: 41ec

Gene Ratzlaff  Feb 18, 2014 
Mobi Page 39
First and third bullets

(Page reference taken from PDF version) Neither bullet successfully ends the sentence. "descende" should read "descended." "wit" should read "with."

Jonathan Hansford  Apr 17, 2013 
Mobi Page 40
Figure 3-5

(Page reference taken from PDF version) Text for figure 3.5 incomplete "fi" should read "file" This type of issue is appearing throughout the document at the end of paragraphs

Jonathan Hansford  Apr 17, 2013 
Printed Page 53
Figure 4-7

The node id in the "First Parent" box should be 7b064d8bac5e not e7639888bb2f.

Peter Williams  Aug 09, 2009 
Printed Page 72
10th line from bottom

export HGMERGE=merge sets the command to be run to 'merge' not to the command 'false' as stated in the next line.

Anthon van der Neut  Sep 07, 2009 
Printed Page 130
second paragraph and last paragraph

After performing the 'hg backout', the parent of the working directory is still 2:third change. The entire discussion at the bottom of the page "Let's think about what we expect to see..." is incorrect. The contents of myfile will contain all three lines until we 'hg merge'.

Kevin McCarthy  Aug 21, 2009 
Printed Page 131
Both command snippets

The output from both command sequences is unexpected/incorrect. The "cat myfile" will output all three lines, as Kevin notes for p130, the working directory is still at r2. The "hg merge" is reported as aborting due to uncommitted changes, presumably the same (not shown) change that caused the incorrect cat output above. In fact, the merge will succeed. As a result, the final "cat myfile" will display: first change third change as one would hope the backout result to be.

Sean A Reith  Apr 22, 2010 
Printed Page 175
First dot point

"\: Backslash" should be "\\: Backslash".

Sean A Reith  Apr 22, 2010 
Printed Page 192
Safety Checks, and Overriding Them example

The example is not the correct example. It should show what happens when a qnew is performed with an outstanding change. Instead it is showing that creating the same patch file twice generates and error.

Kevin McCarthy  Aug 21, 2009 
Printed Page 192
Throughout chapter 12

Throughout chapter 12, the hg commands mistakenly have 'hg' repeated inside the command. On p.192 it has 'hg qnew hg -f' which should be 'hg qnew -f'. This also occurs on p.197,198,201, and probably several others.

Kevin McCarthy  Aug 21, 2009 
Printed Page 192
2nd text paragraph

The inline examples: hg qnew hg -f and hg qpop hg -f are confusing as the second use of hg is the name of patch. In other examples they are more clearly marked with xxxx.patch and the multiline example above the paragraph uses '-f patchname' instead of 'patchname -f'. The examples would be less confusing if they read: hg qnew -f some.patch and hg qpop -f some.patch

avanderneut  Sep 07, 2009 
Printed Page 209
7th paragraph

"arguments to the hg + qguard command" the plus is superfluous.

Sean A Reith  Apr 23, 2010 
Printed Page 211
4th bullet under MQ's Rules for Applying Patches

If a patch has a negative guard, but it doesn't match the currently selected guard, the patch is applied. Therefore the fourth bullet isn't correct to say the patch is skipped. (I think - the whole section left me a bit confused).

Kevin McCarthy  Aug 21, 2009 
Printed Page 211
MQ's Rules for Applying Patches

The fourth bullet point is incorrect, if there is a positive guard that isn't specified, the patch isn't applied. The statement on the previous page that negative guards take precedence over positive is misleading IMHO. An alternative description of the rules might be: # If the patch has any positive guards that are not selected, then the patch will be skipped, # If the patch has any negative guards that are selected, then patch will be skipped, # Otherwise the patch will be applied. Test script (its a windows batch, deal): mkdir qguardrepo cd qguardrepo hg init echo [extensions] >> .hg/hgrc echo hgext.mq = >> .hg/hgrc hg qinit for %%i in (A, B, C, D, E, F, G, H) do ( echo %%i > %%i.txt hg add %%i.txt hg qnew %%i.patch ) hg qguard -- B.patch +one +three hg qguard -- C.patch +three hg qguard -- D.patch +one -three hg qguard -- E.patch -three hg qguard -- F.patch +one -two hg qguard -- G.patch -two hg qguard -- H.patch -three +four hg qselect one two hg qpop -a hg qpush -a dir /b hg --version The output from the last three commands is: $ hg qpush -a applying A.patch applying B.patch skipping C.patch - guarded by ['+three'] applying D.patch applying E.patch skipping F.patch - guarded by '-two' skipping G.patch - guarded by '-two' skipping H.patch - guarded by ['+four'] now at: E.patch $ dir /b .hg A.txt B.txt D.txt E.txt $ hg --version Mercurial Distributed SCM (version 1.5.1) PS. It would be nice to have a preview for the errata submissions...

Sean A Reith  Apr 23, 2010 
Printed Page 211
errata

Errata errata :) Case in point for the value of a preview :) "If the patch has any positive guards that are not selected, then the patch will be skipped," should be "If the patch has any positive guards, and none of them are selected, then the patch will be skipped,"

Sean A Reith  Apr 23, 2010 
Printed Page 221
Third paragraph

The paragraph starts 'As the "making snapshot" lines of output above imply...". There are no apparent lines of output quoted above that contain "making snapshot".

curiousdragon  Apr 25, 2010 
Printed Page 222
Cherry-Picking Changes with the Transplant Extension

The entire section of "Cherry-Picking Changes with the Transplant Extension" contains only this text: "Need to have a long chat with Brendan about this."

Daniel Jimenez  Aug 13, 2009 
Printed Page 234
First title

"qfold - Move Applied Patches into Repository History" should be "qfinish - Move..."

curiousdragon  Apr 25, 2010 
Printed Page 235
Fourth paragraph

In hg 1.5 (and presumably the version used for the example on p192) qnew incorporates any changes in the workspace into the created patch, and the -f option is deprecated.

curiousdragon  Apr 26, 2010 
Printed Page 236
Second paragraph

This paragraph states that qpop does not read the series file. The immediately previous paragraph indicated that it resolves indexes by referencing the series file, hence clearly reading it.

curiousdragon  Apr 26, 2010 
Printed Page 236
Fifth paragraph

(quibble) The qprev description indicates that it uses the series file to determine the previous patch, and that this patch will become the topmost patch if qpop is used. This presumably presupposes that you haven't edited the series file as described earlier in the page under qpop (in which case qpop may be interacting with patches no longer in the series). Perhaps in such circumstances qprev simply prints nothing...

curiousdragon  Apr 26, 2010