Git development
 help / color / mirror / Atom feed
From: Neil Schemenauer <nas@arctrix.com>
To: git@vger.kernel.org
Subject: New converstion tool: svn2git.py
Date: Wed, 19 Nov 2008 13:13:21 -0600	[thread overview]
Message-ID: <20081119191320.GA20870@arctrix.com> (raw)

Hi,

I'm working on a tool to do conversions from SVN to git using a SVN
dump.  It's in early development but perhaps some people would be
interested in it:

    http://python.ca/nas/python/svn2git.py

I would like to improve it so that it intelligently converts SVN
branches and tags into git branches (when possible).  The basic idea
is to map SVN paths into git branches, e.g. trunk -> master,
branches/foo -> branch-foo, tags/bar -> tags-bar.  Next, specific
SVN dump actions like:

    Node-path: branches/foo
    Node-kind: dir
    Node-action: add
    Node-copyfrom-rev: 3
    Node-copyfrom-path: trunk

need to be detected and the commit needs to performed with the
correct parent.  One complication is that SVN can create a branch or
tag from anywhere, for example, the action

    Node-path: tags/bar
    Node-kind: dir
    Node-action: add
    Node-copyfrom-rev: 3
    Node-copyfrom-path: trunk/subdir

would create tags/bar based on revision 3 of trunk/subdir.  There
doesn't seem to be a good way to convert that into git.  I was
thinking that the tags-bar branch in that case would have no parent.
Would git still efficently pack that or would you end up with extra
blobs?

  Neil

             reply	other threads:[~2008-11-19 19:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-19 19:13 Neil Schemenauer [this message]
2008-11-19 19:39 ` New converstion tool: svn2git.py Kevin Menard
2008-11-19 20:40   ` Neil Schemenauer
2008-11-20 18:49 ` Daniel Barkalow

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20081119191320.GA20870@arctrix.com \
    --to=nas@arctrix.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox