[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] FAQ additions

From: Paul Lussier <pll_at_lanminds.com>
Date: 2002-10-11 19:03:26 CEST

>>>>> On Thu, 10 Oct 2002, "pll" == pll@lanminds.com wrote:

  pll> Hi all,

  pll> I've added the following FAQs to the project_faq.html file:

  pll> # How do I check out the Subversion code? How do I manage
  pll> # several different projects under Subversion? How do I merge
  pll> # two completely separate repositories? How do I submit a
  pll> # patch for Subversion?

  pll> With answers.

  pll> I've also added a "Back to top..." link under each major
  pll> section and under the answer to each question for easier
  pll> navigation.

  pll> I've quoted a few people from the list and included their
  pll> names/ e-mail addresses for proper attribution, I hope that's
  pll> okay. (I added NOSPAM to the e-mail addresses just in case!).

  pll> The patch is in-line below.

>>>>> On Thu, 10 Oct 2002, "Colin" == Colin Watson wrote:

  Colin> Those look like they should be 'svnadmin dump' and 'svnadmin
  Colin> load' respectively.

>>>>> On Fri, 11 Oct 2002, "pll" == pll@lanminds.com wrote:

  pll> Care to make the correction, or should I and resubmit the patch?

>>>>> On 11 Oct 2002, "Karl" == Karl Fogel wrote:

  Karl> Would you mind doing that? It makes things a little easier
  Karl> if we have a "latest patch with all review incorporated"...
  Karl> at least, the way I'm managing my ever-growing patch archive,
  Karl> this makes it easier :-).

Here you go!

Seeya,
Paul

>8<----------------------8<----------------------8<----------------------8<----Index: www/project_faq.html
===================================================================
--- www/project_faq.html
+++ www/project_faq.html Fri Oct 11 12:49:53 2002
@@ -1,4 +1,4 @@
-<h1>Subversion FAQ</h1>
+<a name="top"><h1>Subversion FAQ</h1></a>
 
 <p>
 
@@ -31,14 +31,25 @@
 <li><a href="#more-information">I have other questions. Where can I
     get more information?</a></li>
 <p>
+
+<p>Back to top...</p>
+
 <strong>How-to:</strong>
 </p>
+<li>How do I check out the Subversion code?</li>
 <li><a href="#repository">How do I create a repository? How do I
     import data into it?</a></li>
 <li>What if I'm behind a proxy?</li>
 <li><a href="#paranoid">My admins don't want me to have a HTTP server for
     Subversion. What can I do if I still want remote usage?</a></li>
+<li><a href="#multi-proj">How do I manage several different projects
+ under Subversion?</li></a>
+<li>How do I merge two completely separate repositories?
+<li>How do I submit a patch for Subversion?</li>
 <p>
+
+<p>Back to top...</p>
+
 <strong>Troubleshooting:</strong>
 </p>
 <li><a href="#unrecognized-url-error">I just built the distribution
@@ -59,6 +70,9 @@
     server sometimes seems to send out corrupted data. Can this really be
     happening?</a></li>
 <p>
+
+<p>Back to top...</p>
+
 <strong>References:</strong>
 </p>
 <li><a href="#http-methods">What are all the HTTP methods Subversion
@@ -82,6 +96,8 @@
 revision control system that is very similar to CVS, but fixes many
 things that are broken. See our front page.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="collab">Is Subversion proprietary? I heard that it
@@ -98,6 +114,8 @@
 modify, and redistribute Subversion as you please; no permission from
 CollabNet or anyone else is required.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="stable">Is Subversion stable enough for me to use for my
@@ -132,6 +150,8 @@
 
 </ul>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="portability">What operating systems does Subversion run
@@ -154,6 +174,8 @@
 practice, it's difficult to get the Subversion repository running on
 non-Unix platforms; if you succeed, we'd like to hear about it.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="filesystem">What's all this about a new filesystem? Is
@@ -169,6 +191,8 @@
 that this particular filesystem doesn't lose data when written to; old
 versions of files and directories are saved.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="apache-extension">I heard that Subversion is an Apache
@@ -182,6 +206,8 @@
 its network protocol, see our <a
 href="http://subversion.tigris.org/servlets/ProjectDocumentList">docs.</a></p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="need-apache">Does this mean I have to set up Apache to
@@ -194,6 +220,8 @@
 server, please read our <a
 href="http://svn.collab.net/repos/svn/trunk/INSTALL">INSTALL</a> document.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3>I run Apache 1.x right now, and can't switch to Apache 2.0 just to
@@ -208,6 +236,8 @@
 make sure to specify that port when you publish your repository URL
 (e.g., <tt>http://svn.mydomain.com:8080/repos/blah/trunk/</tt>).</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="feature-x">Why don't you do X, just like SCM system Y?</a></h3>
@@ -216,6 +246,8 @@
 attempting to imitate all the best features of every SCM system out
 there. We're trying to replace CVS. See the first question.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="globalrev">Why does the entire repository share the
@@ -239,6 +271,8 @@
 get a much better picture of a code-base's rate of change.
 </p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="release">When's the next release?</a></h3>
@@ -247,6 +281,8 @@
 href="http://subversion.tigris.org/project_status.html">
 http://subversion.tigris.org/project_status.html</a>.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3>I have other questions. Where can I get more<a
@@ -258,6 +294,8 @@
 channel #svn on <a
 href="http://www.openprojects.net">irc.openprojects.net</a>.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[=========================================================]]>
 
 <p>
@@ -268,6 +306,14 @@
 
 <![CDATA[-----------------------------------------------------------]]>
 
+<h3><a name="co-svn">How do I check out the Subversion code?</a></h3>
+<p>Use the subversion client:
+<pre>
+ svn co http://svn.collab.net/repos/svn/trunk subversion
+</pre>
+<p>
+<p>Back to top...</p>
+
 <h3><a name="repository">How do I create a repository? How do I
 import data into it?</a></h3>
 
@@ -276,6 +322,8 @@
 http://svn.collab.net/repos/svn/trunk/README</a>; specifically, look
 at section IV, the "Quickstart Guide".</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="proxy">What if I'm behind a proxy?</a></h3>
@@ -332,6 +380,8 @@
 <tt>./configure</tt> script. You can check to see whether the 'https'
 schema is supported by running <tt>svn --version</tt>.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[=========================================================]]>
 
 <h3><a name="paranoid"/>My admins don't want me to have a HTTP server for
@@ -399,8 +449,139 @@
 <li>TTSSH: A Win32 SSH client capable of port forwarding</li>
 </ul>
 
+<p>Back to top...</p>
+
+<![CDATA[=========================================================]]>
+
+<h3><a name="multi-proj">How do I manage several different projects under Subversion?</a></h3>
+
+<p>It depends upon the projects involved. If the projects are
+related, and are likely to share data, then it's best to create one
+repository with several subdirectories like this:
+<pre>
+ $ svnadmin create /repo/svn
+ $ svn mkdir file:///repo/svn/projA
+ $ svn mkdir file:///repo/svn/projB
+ $ svn mkdir file:///repo/svn/projC
+</pre>
+
+If the projects are completely unrelated, and not likely to share data
+between them, then it's probably best to create separate and unrelated
+repositories.
+<pre>
+ $ mkdir /repo/svn
+ $ svnadmin create /repo/svn/projA
+ $ svnadmin create /repo/svn/projB
+ $ svnadmin create /repo/svn/projC
+</pre>
+<p>
+The difference between these two approaches is this (as explained by
+Ben Collins-Sussman <sussman@NOSPAMcollab.net>):
+
+<ul>
+ <li>
+ <pre>
+ In the first case, code can easily be copied or moved around
+ between projects, and the history is preserved. ('svn cp/mv'
+ currently only works within a single repository.)
+ </pre>
+ </li>
+ <li>
+ <pre>
+ Because revision numbers are repository-wide, a commit to any
+ project in the first case causes a global revision bump. So it
+ might seem a bit odd if somebody has 'projB' checked out, notices
+ that 10 revisions have happened, but projB hasn't changed at
+ all. Not a big deal, really. Just a little weird at first.
+ This already happens to svn, everytime people commit to
+ rapidsvn. :-)
+ </pre>
+ </li>
+ <li>
+ <pre>
+ The second case might be easier to secure; it's easier to insulate
+ projects from each other (in terms of users and permissions)
+ using Apache's access control. In the 2nd case, you'll need a
+ fancy hook script in the repository that distinguishes projects
+ ("is this user allowed to commit to this particular subdir?") Of
+ course, we already have such a script, ready for you to use.
+ </pre>
+ </li>
+</ul>
+<p>Back to top...</p>
+
 <![CDATA[=========================================================]]>
 
+<h3><a name="multi-merge">How do I merge two completely separate repositories?</a></h3>
+
+<p>If you don't care about retaining all the history of one of the
+repositories, you can just create a new directory under one project's
+repository, then import the other.
+
+<p>If you care about retaining the history of both, then you can use
+'svnadmin dump' to dump one repository, and 'svnadmin load' to load it into
+the other repository. The revision numbers will be off, but you'll
+still have the history.
+
+<p>Peter Davis <peter@NOSPAMpdavis.cx> also explains a method using svn's
+equivalent to CVS modules:
+
+<p><blockquote>
+
+ <p>As long as the merging takes place in separate directory
+ trees, you can use svn's version of CVS modules.
+
+ <p>Set the <em>svn:externals</em> property on a directory to checkout
+ directories from other repositories whenever the original
+ directory is checked out. The repository remains separate,
+ but in the working copy it appears that they have been merged.
+ If you commit to the imported directory, it will affect the
+ external repository.
+
+ <p>The merge isn't completely clean: the import only affects
+ working copies, so you won't be able to use a URL in the first
+ repository to access modules imported from the second. They
+ remain separate URLs.
+</blockquote>
+
+<p>Back to top...</p>
+
+<![CDATA[=========================================================]]>
+
+<h3><a name="patch">How do I submit a patch for Subversion?</a></h3>
+
+<p>FIRST, read the HACKING document.
+
+<p>Once you've digested that, send a mail to the dev list with the word
+[PATCH] and a one-line description in the subject, and include the
+patch inline in your mail (unless your MUA munges it up totally). Then
+a committer will pick it up, apply it (making any formatting or
+content changes necessary), check it in, and hit the magic button that
+updates the Tigris site.
+
+<p>The basic process looks like this:
+<pre>
+<blockquote>
+ $ svn co http://svn.collab.net/repos/svn/trunk subversion
+ $ cd subversion/www
+
+ [ make changes to project_faq.html ]
+
+ $ svn diff project_faq.html > /tmp/foo
+
+ $ Mail -s "[PATCH] FAQ updates" < /tmp/foo
+</blockquote>
+</pre>
+
+Of course, the e-mail you send should contain a nice long
+explanation about what the patch does, as per the
+<ahref="http://svn.collab.net/repos/svn/trunk/HACKING">HACKING</a>
+document, but you already know that, since you read and completely
+understood it <em>before</em> actually hacking the code, right? :)
+
+<p>Back to top...</p>
+
+<![CDATA[=========================================================]]>
 <p>
 <hr>
 <p>
@@ -432,6 +613,8 @@
 can also specify the library directory in the LD_LIBRARY_PATH environment
 variable.</p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3><a name="db-recover">I'm getting errors finding or opening a repository,
@@ -479,6 +662,8 @@
 at all. We're working on it, and volunteers are welcome :-).
 </p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3>I'm getting strange errors in my httpd error log, and Subversion
@@ -498,6 +683,8 @@
 will sometimes be necessary.
 </p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3>When I run `<tt>configure</tt>', I get errors about
@@ -512,6 +699,8 @@
 building with are completely up-to-date, and try again.
 </p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
  
 <h3>I'm having trouble building Subversion under Windows with MSVC++ 6.0.
@@ -522,6 +711,8 @@
 ships with VC++ 6.0 is not recent enough.
 </p>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3>I'm running Subversion under windows and I can create a repository
@@ -541,6 +732,8 @@
 svn import file:///some/path/to/repos/on/d/drive e:\file\to\be\imported
 </pre>
 
+<p>Back to top...</p>
+
 <![CDATA[-----------------------------------------------------------]]>
 
 <h3>I'm having trouble doing write <a name="write-over-dav">
@@ -575,6 +768,8 @@
 the httpd process. Check the permissions to ensure Apache can write
 to the <tt>dav/</tt> directory (and to <tt>db/</tt>, of course). </p>
 
+<p>Back to top...</p>
+
 <![CDATA[=========================================================]]>
 
 
@@ -613,6 +808,8 @@
 Windows XP."</p>
 
 
+<p>Back to top...</p>
+
 <![CDATA[=========================================================]]>
 
 
@@ -680,6 +877,8 @@
 </blockquote>
 
 </p>
+
+<p>Back to top...</p>
 
 <![CDATA[-----------------------------------------------------------]]>
 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Oct 11 19:04:09 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.