From: "David Frech" <david@nimblemachines.com>
To: "Julian Phillips" <julian@quantumfyre.co.uk>
Cc: git@vger.kernel.org
Subject: Re: Another question about importing SVN with fast-import
Date: Thu, 19 Jul 2007 00:09:41 -0700 [thread overview]
Message-ID: <7154c5c60707190009r6d460debs71158d4db9a028d4@mail.gmail.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0707162204480.14971@reaper.quantumfyre.co.uk>
On 7/16/07, Julian Phillips <julian@quantumfyre.co.uk> wrote:
> Now the question. Shawn recently added C and R operations - almost as
> soon as they were asked for too. However, how do you copy a file from a
> particular revision? I have just hit a point where someone deleted a
> directory, and then copied one of the files from that directory back from
> an old revision (as two separate commits). Since I'm not tracking any
> branch contents in my front-end, and the copy operation only works from
> the current branch head I seem to be stuck ... or have I missed something?
I have to second Julian's question.
The only things I have left to implement (in my svn dump to
fast-import translator) before I can call my code "complete" are
branch copies (which will generate "from" lines in commits so
fast-import can properly initialize the new branch) and a generic
"copy <path> from <rev>" that Julian also needs.
I mark my commits and keep track of the mapping from svn revs to git
commits, so when the svn dump asks for a <path> from a specific <svn
rev> I can correlate that to a mark (ie, a git commit). But I can't
tell fast-import to *do* anything with it.
This is kind of a request and a comment/question. The request is:
there is no way to do *reasonably* in the front end what fast-import
can do somewhat reasonably: namely, copy a <path> (file or directory!)
from an arbitrary previously committed revision/mark to the current
branch.
The comment/question is: how different is this, really, from being
able to specify a "from" line in a commit? In both cases I'm asking
fast-import to reach into its memory (or the repo) and pull out a
tree, and to add (some or all of it) to my current branch. Isn't the
kind of generic C command that Julian and I are asking for the same
thing, only instead of taking the whole tree (from the specified
commit) it takes a single file or directory?
I hope I haven't missed the point entirely.
Lastly, do we really need "R"? With this generic copy - and I think
there should be *only* a generic version, not a "streamlined local
copy" version and a "reach into history arbitrarily" version - we can,
as an earlier poster pointed out, do R by doing a C and then a D. This
is, in fact, how svn dump files represent file and directory renames.
It would be nice to keep the fast-import command set small and orthogonal.
My few cents.
Cheers,
- David
--
If I have not seen farther, it is because I have stood in the
footsteps of giants.
next prev parent reply other threads:[~2007-07-19 7:09 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-16 21:11 Another question about importing SVN with fast-import Julian Phillips
2007-07-17 3:38 ` Shawn O. Pearce
2007-08-06 13:13 ` Julian Phillips
2007-08-07 1:08 ` Shawn O. Pearce
2007-07-19 7:09 ` David Frech [this message]
2007-07-20 5:11 ` Shawn O. Pearce
2007-07-20 5:50 ` Julian Phillips
2007-07-20 6:54 ` David Frech
2007-07-20 7:01 ` Julian Phillips
2007-07-20 7:16 ` David Frech
2007-07-23 18:06 ` Jan Hudec
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=7154c5c60707190009r6d460debs71158d4db9a028d4@mail.gmail.com \
--to=david@nimblemachines.com \
--cc=git@vger.kernel.org \
--cc=julian@quantumfyre.co.uk \
/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;
as well as URLs for NNTP newsgroup(s).