hgbook

changeset 695:fd2e83ffb165

Add paragraph tags
author Bryan O'Sullivan <bos@serpentine.com>
date Tue Apr 28 23:14:14 2009 -0700 (2009-04-28)
parents 88828b784971
children 9e33729cafae
files en/appA-svn.xml
line diff
     1.1 --- a/en/appA-svn.xml	Tue Apr 28 23:10:43 2009 -0700
     1.2 +++ b/en/appA-svn.xml	Tue Apr 28 23:14:14 2009 -0700
     1.3 @@ -75,7 +75,7 @@
     1.4        <filename>.hg/shamap</filename> inside the target
     1.5        repository.</para>
     1.6  
     1.7 -    <para>When you want to start making changes using Mercurial, it's
     1.8 +    <para id="x_707">When you want to start making changes using Mercurial, it's
     1.9        best to clone the tree in which you are doing your conversions,
    1.10        and leave the original tree for future incremental conversions.
    1.11        This is the safest way to let you pull and merge future commits
    1.12 @@ -85,7 +85,7 @@
    1.13      <sect2>
    1.14        <title>Converting multiple branches</title>
    1.15  
    1.16 -      <para>The <command>hg convert</command> command given above
    1.17 +      <para id="x_708">The <command>hg convert</command> command given above
    1.18  	converts only the history of the <literal>trunk</literal>
    1.19  	branch of the Subversion repository.  If we instead use the
    1.20  	URL <literal>http://python-nose.googlecode.com/svn</literal>,
    1.21 @@ -95,7 +95,7 @@
    1.22  	usually use, and it will import each as a separate Mercurial
    1.23  	branch.</para>
    1.24  
    1.25 -      <para>By default, each Subversion branch imported into Mercurial
    1.26 +      <para id="x_709">By default, each Subversion branch imported into Mercurial
    1.27  	is given a branch name.  After the conversion completes, you
    1.28  	can get a list of the active branch names in the Mercurial
    1.29  	repository using <command>hg branches -a</command>. If you
    1.30 @@ -104,7 +104,7 @@
    1.31  	  convert.hg.usebranchnames=false</option> option to
    1.32  	<command>hg convert</command>.</para>
    1.33  
    1.34 -      <para>Once you have converted your tree, if you want to follow
    1.35 +      <para id="x_70a">Once you have converted your tree, if you want to follow
    1.36  	the usual Mercurial practice of working in a tree that
    1.37  	contains a single branch, you can clone that single branch
    1.38  	using <command>hg clone -r mybranchname</command>.</para>
    1.39 @@ -183,7 +183,7 @@
    1.40      <sect2>
    1.41        <title>Improving Subversion conversion performance</title>
    1.42  
    1.43 -      <para>You will often need several attempts before you hit the
    1.44 +      <para id="x_70b">You will often need several attempts before you hit the
    1.45  	perfect combination of user map, file map, and other
    1.46  	conversion parameters.  Converting a Subversion repository
    1.47  	over an access protocol like <literal>ssh</literal> or
    1.48 @@ -192,7 +192,7 @@
    1.49  	network delays.  This can make tuning that perfect conversion
    1.50  	recipe very painful.</para>
    1.51  
    1.52 -      <para>The <ulink
    1.53 +      <para id="x_70c">The <ulink
    1.54  	  url="http://svn.collab.net/repos/svn/trunk/notes/svnsync.txt"><command>svnsync</command></ulink> 
    1.55  	command can greatly speed up the conversion of a Subversion
    1.56  	repository.  It is a read-only mirroring program for
    1.57 @@ -200,41 +200,41 @@
    1.58  	mirror of your Subversion tree, then convert the mirror into a
    1.59  	Mercurial repository.</para>
    1.60  
    1.61 -      <para>Suppose we want to convert the Subversion repository for
    1.62 +      <para id="x_70d">Suppose we want to convert the Subversion repository for
    1.63  	the popular Memcached project into a Mercurial tree.  First,
    1.64  	we create a local Subversion repository.</para>
    1.65  
    1.66        <screen><prompt>$</prompt> <userinput>svnadmin create memcached-mirror</userinput></screen>
    1.67  
    1.68 -      <para>Next, we set up a Subversion hook that
    1.69 +      <para id="x_70e">Next, we set up a Subversion hook that
    1.70  	<command>svnsync</command> needs.</para>
    1.71  
    1.72        <screen><prompt>$</prompt> <userinput>echo '#!/bin/sh' > memcached-mirror/hooks/pre-revprop-change</userinput>
    1.73  <prompt>$</prompt> <userinput>chmod +x memcached-mirror/hooks/pre-revprop-change</userinput></screen>
    1.74  
    1.75 -      <para>We then initialize <command>svnsync</command> in this
    1.76 +      <para id="x_70f">We then initialize <command>svnsync</command> in this
    1.77  	repository.</para>
    1.78  
    1.79        <screen><prompt>$</prompt> <userinput>svnsync --init file://`pwd`/memcached-mirror \
    1.80    http://code.sixapart.com/svn/memcached</userinput></screen>
    1.81  
    1.82 -      <para>Our next step is to begin the <command>svnsync</command>
    1.83 +      <para id="x_710">Our next step is to begin the <command>svnsync</command>
    1.84  	mirroring process.</para>
    1.85  
    1.86        <screen><prompt>$</prompt> <userinput>svnsync sync file://`pwd`/memcached-mirror</userinput></screen>
    1.87  
    1.88 -      <para>Finally, we import the history of our local Subversion
    1.89 +      <para id="x_711">Finally, we import the history of our local Subversion
    1.90  	mirror into Mercurial.</para>
    1.91  
    1.92        <screen><prompt>$</prompt> <userinput>hg convert memcached-mirror</userinput></screen>
    1.93        
    1.94 -      <para>We can use this process incrementally if the Subversion
    1.95 +      <para id="x_712">We can use this process incrementally if the Subversion
    1.96  	repository is still in use.  We run <command>svnsync</command>
    1.97  	to pull new changes into our mirror, then <command>hg
    1.98  	  convert</command> to import them into our Mercurial
    1.99  	tree.</para>
   1.100  
   1.101 -      <para>There are two advantages to doing a two-stage import with
   1.102 +      <para id="x_713">There are two advantages to doing a two-stage import with
   1.103  	<command>svnsync</command>.  The first is that it uses more
   1.104  	efficient Subversion network syncing code than <command>hg
   1.105  	  convert</command>, so it transfers less data over the