Nathan Cournia wrote:
> Thanks for the reply.
> 
> I've hacked my way around the problem for the time being.  Attached is patch.
> 
> The patch basically adds any subdirectories it sees in each changeset.
>  This means that in each changeset a directory appears, the patch will
> try to re-add the directory.
> 
> It's a horrible hack, but it does work (in my case) when going from
> monotone to svn.  I can think of many ways to easily break this hack,
> so I don't really recommend it to anyone.  Hopefully, the patch will
> inspire someone more knowledgeable in monotone and tailor to write
> proper support.
More or less, is the same hack I am doing. Since monotone handles
directories implicitly, and the monotone backend must also fake
changesets to linearize, a full dir support will be very complex.
Besides, there are ongoing development on monotone itself to handle
directories explicitly.

> I've also found another problem with tailor's monotone->svn
> conversion.  In monotone, if I do the following:
> 
> monotone rename a b
> monotone add a
> monotone commit
> 
> and then try to convert to svn, tailor will loose a.
> 
> With that said, I'm not sure if it's fair to label monotone as a
> "fully supported" source system.
This is a limitation on the svn part, not monotone.
You need to understand how tailor works: for every changeset, the source
backend populates its working directory with the *result* of the
changeset (in your case, with both a and b).
Changeset entries are then replayed on the target backend, renames
first. In your case, executes an svn mv, wich fails because b already
exists (note that *every* rename fails this way, not just yours).
Seeing a failure, tailor tries to workaround replicating svn behaviour
by doing a remove+add (svn remove oldname svn add newname).
Unfortunately, svn remove oldname also removes the *new* a from the
working dir, so when tailor replays the svn add a the file is missing.
To be fair, I suspect most backends will have problem handling corner
cases like yours.
For example, add a + rename a b generates the same changeset of rename a
b + add a (in this particular case the working dir will be different,
though), making difficult to disambiguate correctly.

Greetings,
Riccardo

_______________________________________________
Tailor mailing list
[email protected]
http://lists.zooko.com/mailman/listinfo/tailor

Reply via email to