We have a subversion repository and just discovered that files in the subversion repository where moved from one folder to another using the filesystem operations resulting in a deletion and an addition to subversion. As expected history of the file was not taken over to the new location.
Is it possible to convert this wrongly done move into a true svn mv where the history is copied along?
The problem is that the commit has been a while back and there have been several commits on top of this commit. So a simple reverse merge and a proper move are out of option.
We have a subversion repository and just discovered that files in the subversion repository
Share
It is possible assuming you have direct access to the repository, can dump and reload it, so assuming.
In short the steps are:
you need to dump the repository, modify the dump, delete, recreate and load the repository.
Required Dumpfile Modification
Your wrong move operation in the dumpfile will look something like that:
For further reading the dump file specification is worth checking out, however for your problem only a small set of entries are relevant: There are two nodes, one with
Node-action: add, the other withNode-action: delete. All you need to do is to modify the dump so that it looks like:Thus, you need replace
with
and remove the actual content of the file.
The
deleteaction stays unchanged.