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

Re: mv != (cp && rm)

From: Karl Fogel <kfogel_at_newton.ch.collab.net>
Date: 2001-11-28 00:01:22 CET

Mattias Rönnblom <hofors@lysator.liu.se> writes:
> currently, svn mv is implemented by adding a new node and and
> removing the old. This means that a file that is moved get
> a new id, and there is now way of know wheter it is a actual
> copy of the node in question, or if the user only wanted to
> change the name of the node.

Yes, there is a way -- the "history" is preserved in the repository.
The newly created node knows that it is derived from the old node.
See the `copy properties' in libsvn_fs.

What you say about capturing the users' intention is true, but
unfortunately that is not a problem of the mv operation itself, but
rather of the commit. If the user chooses to commit only one side or
the other of the move first, then you have one case. If she commits
both sides in one commit, then you know it's a rename. This
information is in the repository.

IOW, because the user can choose to commit only part of the mv at a
time, this issue is a little more complex than it might at first
appear. :-)


To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Oct 21 14:36:49 2006

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