savannah-hackers-public
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Savannah-hackers-public] documentation changes for converting from svn


From: Bob Proulx
Subject: [Savannah-hackers-public] documentation changes for converting from svn to git
Date: Sun, 25 Nov 2018 13:28:23 -0700
User-agent: Mutt/1.10.1 (2018-07-13)

Gavin Smith wrote:
> +To access a local copy of the repository, use svnserve:
> +
> +    svnserve -d -r svn_repo
> +
> +Then access it with git svn with something like:
> +
> +    git svn clone svn://127.0.0.1/myproject -A authors-transform.txt 
> --stdlayout ./temp.checkout
> + 
> +where myproject is the subdirectory under svn_repo.

There is actually no need to start a local svn server and I wouldn't
recommend it in the docs.  Instead use the path to the local file as
shown in the previous section.

  file:///path/to/svn_repo

Note the URL format for the local files.  Meaning three slashes.  As
"file://" is the scheme and "/path/to" is the path and the host part
being empty defaults to localhost.  Note that I'm just the messenger
here!

  https://en.wikipedia.org/wiki/File_URI_scheme

Doing that means there is no need for a running svnserve process.
Therefore that is my recommendation.  You might try this:

  git svn clone file://tmp/scratch/myproject -A authors-transform.txt 
--stdlayout ./temp.checkout

But looking at that import section there are other problems.  The docs
in that section were from the previous Zwiki import after the
"Big Zwiki Crash and Recovery" some years ago.  The previous history
was lost.  Currently they say:

    Git comes with 2 SVN-related tools: `git-svnimport` and `git-svn`.
    `git-svnimport` is for importing revisions (a one-shot import, or
    incrementally); `git-svn` is a 2-way gateway to a SVN repository,
    similar to SVK, more useful for maintaining a local branch than for
    importing a repository (IMHO). We'll use `git-svnimport`.

Does git now come with 'svnimport'?  I went looking just now and I
could not find any such tool.  Nor reference to any such tool on the
net.  I think that part needs to be removed and the conversion process
updated.

There are dozens of conversion guides written by numerous people on
the net for converting from one repository to another.  It is probably
better for us to reference one and redirect readers there rather than
try to duplicate the process in the Savannah docs.  That would be my
preference.  But regardless the current docs saying git-svnimport seem
problematic.

For simple histories I have used the simple process described here:

  
http://jonmaddox.com/2008/03/05/cleanly-migrate-your-subversion-repository-to-a-git-repository/

The above doesn't try to import tags and each branch must be converted
individually.  But it is very simple and easy to understand which is a
huge plus.  The git scm book outlines a much more complicated process:

  https://git-scm.com/book/en/v2/Git-and-Other-Systems-Migrating-to-Git

And then there is ESR's reposurgeon which he created for the emacs project
conversion:

  http://www.catb.org/esr/reposurgeon/
  http://www.catb.org/~esr/reposurgeon/dvcs-migration-guide.html

To be honest reposurgeon is a large and complicated tool and the
thought of using it myself causes my eyes to go a little wide with
terror.  But it has been used for large repositories and help is
available to run it.  If someone had simple examples then it would
probably be the best conversion tool.

Are there better conversion guides?

WDYT?

Bob

P.S. I started a new thread and changed the subject to match the
conversion direction. :-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]