ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > Coding Snacks

Svn Conflicts Backup - Redo your subversion conflict resolves

(1/1)

justice:
After wasting my morning wrestling with subversion, in particularly this question:
Subversion reverting resolved file
If I was to make an error in a file that I have marked resolved is there a way to go back to having the file in it's original conflicted state without reverting all changes and reattempting the merge?
--- End quote ---
No, there is no automatic way to do that. If you want to be able to do that, you'll have to manually back up the .mine file ahead of time so that you can get it back if needed.
--- End quote ---
SpoilerI'm doing a merge. After merging I commit all files without conflicts. Then I resolve single files and commit them. If I make a mistake how do I redo the resolving (even if I haven't committed the resolved file yet)?

Contrary to expectation I cannot revert the file. When reverting back to any step after the merge none of the files become conflicted again. This means I have one chance to resolve correctly or having to revert the wc to a point before the merge and reattempt the merge - which takes a long time.

It seems when doing a merge the act of merging is applied as a property on the working copy root folder, and then the wc is considered merged, whether or not there are conflicts outstanding. Is it right that none of the conflicts are marked as such in the repository?

Deleting the file and doing an svn update did not succeed as I retrieve the file as if it wasn't merged and attempting to merge again does not find any changesets.

Well now you don't have you waste your time, you can redo your conflict resolves using the enclosed script. (included is the .ahk and .exe file). It's a bit spartan but the GUI will guide you throughu the process:

* Select working copy root
* Find all .working files
* For each .working file find all other extensions with the same filename (.merge-left.rXXXX  and .merge-right.rXXXX files and the actual file)
* copy these into a SvnConflictsBackup\<date>\<directory_structure>\file on your desktop
* Show Finished(remove) and Restore button
* Finish: exit and open backup folder for deletion by user
*: choose from all .working files and restore it and related files

When you are resolving conflicts, think of this utility and use it to back them up!

Ath:
Thanks, sounds useful to me :Thmbsup: (yes we do use SVN every day, about 40 projects/repos)

But the biggest drawback is I'd need to be reminded in time to make the backup :-[

justice:
hehe anything you can think I can do to help with that? :)

Ath:
hehe anything you can think I can do to help with that? :)
-justice (February 07, 2012, 02:19 PM)
--- End quote ---
Nope.
I'll probably have to put a big warning sticker on the monitor instead of the brand-logo, that says "BACKUP THE BACKUP" in red on white, hopefully that's enough :tellme:

justice:
If you want to play with the latest source, you can now fork from Bitbucket:
https://bitbucket.org/svandragt/svnconflictsbackup

I'll keep posting executable releases in this topic when they're available.

Navigation

[0] Message Index

Go to full version