[svnbook] r5502 committed - branches/1.8/zh/book/ ch04-branching-and-merging.xml

wuzhouhui at users.sourceforge.net wuzhouhui at users.sourceforge.net
Sun Nov 19 06:47:58 CST 2017


Revision: 5502
          http://sourceforge.net/p/svnbook/source/5502
Author:   wuzhouhui
Date:     2017-11-19 12:47:58 +0000 (Sun, 19 Nov 2017)
Log Message:
-----------
1.8/zh: translation of chapter 4 in progress

Modified Paths:
--------------
    branches/1.8/zh/book/ch04-branching-and-merging.xml

Modified: branches/1.8/zh/book/ch04-branching-and-merging.xml
===================================================================
--- branches/1.8/zh/book/ch04-branching-and-merging.xml	2017-11-18 12:24:21 UTC (rev 5501)
+++ branches/1.8/zh/book/ch04-branching-and-merging.xml	2017-11-19 12:47:58 UTC (rev 5502)
@@ -5362,12 +5362,20 @@
 
     <!-- =============================================================== -->
     <sect2 id="svn.branchmerge.tags.mkcomplex">
+      <!--
       <title>Creating a Complex Tag</title>
+      -->
+      <title>创建复杂的标签</title>
 
+      <!--
       <para>Sometimes you may want a <quote>snapshot</quote> that is
         more complicated than a single directory at a single
         revision.</para>
+      -->
+      <para>有时候, 用户可能需要更复杂的 <quote>快照</quote>, 它不仅仅是单独
+        版本号下的单个目录.</para>
 
+      <!--
       <para>For example, pretend your project is much larger than our
         <filename>calc</filename> example: suppose it contains a
         number of subdirectories and many more files.  In the course
@@ -5383,7 +5391,17 @@
         locations from different revisions.  But after testing, you
         know it's the precise combination of data you need to
         tag.</para>
+      -->
+      <para>举个例子, 假设你的项目比我们的 <filename>calc</filename> 庞大得
+        多: 项目内包含了大量的文件与目录. 在工作过程中, 你可能需要创建一个
+        含有指定特性和问题修正的工作副本, 创建的方式可以是选择性地把文件或
+        目录退回到指定的版本 (使用带有选项 <option>-r</option> 的
+        <command>svn update</command> 命令), 把文件和目录切换到特定的分支
+        (通过命令 <command>svn switch</command>), 甚至是一连串的本地修改.
+        创建完毕后, 你的工作副本就变成了一个大杂烩, 但是在测试后, 你确定这
+        正是你想要创建标签的目标.</para>
 
+      <!--
       <para>Time to make a snapshot.  Copying one URL to another won't
         work here.  In this case, you want to make a snapshot of your
         exact working copy arrangement and store it in the repository.
@@ -5391,6 +5409,12 @@
         different uses (see <xref linkend="svn.ref.svn.c.copy"/> in <xref
         linkend="svn.ref.svn"/>), including the ability to copy a
         working copy tree to the repository:</para>
+      -->
+      <para>是时候创建快照了, 但复制 URL 在这里不起作用. 对于这种情况, 用户
+        想要的是在仓库中, 为当前状态下的工作副本创建一个快照. 幸运的是
+        <command>svn copy</command> 的 4 种用法中 (见 <xref
+          linkend="svn.ref.svn"/> 的 <xref linkend="svn.ref.svn.c.copy"/>),
+        包含了把工作副本复制到仓库中的能力:</para>
 
       <informalexample>
         <screen>
@@ -5405,11 +5429,17 @@
 </screen>
       </informalexample>
 
+      <!--
       <para>Now there is a new directory in the repository,
         <filename>/calc/tags/mytag</filename>, which is an exact
         snapshot of your working copy—mixed revisions, URLs,
         local changes, and all.</para>
+      -->
+      <para>现在, 仓库中就出现了一个新目录 <filename>/calc/tags/mytag
+        </filename>, 它是当前工作副本的快照—混合的版本号, URL, 本地修改
+        等.</para>
 
+      <!--
       <para>Other users have found interesting uses for this feature.
         Sometimes there are situations where you have a bunch of local
         changes made to your working copy, and you'd like a
@@ -5421,7 +5451,17 @@
         collaborator can then either check out a verbatim copy of your
         working copy or use <command>svn merge</command> to receive
         your exact changes.</para>
+      -->
+      <para>有些用户已经发现了这个特性的其他一些用法. 有时候用户的工作副本
+        可能包含了一堆本地修改, 他想让其他用户审核一下, 但这次不是用
+        <command>svn diff</command> 生成并发送补丁 (<command>svn diff</command>
+        无法体现目录或符号链接的变化), 而是用 <command>svn copy</command> 把
+        当前状态下的工作副本 <quote>上传</quote> 到仓库中的适当位置, 例如你的
+        私有目录, 然后其他用户就可以用 <command>svn checkout</command> 逐字
+        拷贝你的工作副本, 或者用 <command>svn merge</command> 接收你做出的修改.
+      </para>
 
+      <!--
       <para>While this is a nice method for uploading a quick snapshot
         of your working copy, note that this is <emphasis>not</emphasis>
         a good way to initially create a branch.  Branch creation should
@@ -5429,6 +5469,11 @@
         of a branch with extra changes to files, all within a single revision.
         This makes it very difficult (later on) to identify a single
         revision number as a branch point.</para>
+      -->
+      <para>虽然这是上传工作副本快照的好办法, 但要注意的是这 <emphasis>不是
+        </emphasis> 一个创建分支的好办法, 创建分支应该是它本身的事件, 而这种
+        方法创建的分支混合了额外的修改, 分支的创建和修改都在一个单独的版本号
+        里, 这样的话我们以后就难确定哪一个版本号才是分支点.</para>
 
     </sect2>
 




More information about the svnbook-dev mailing list