0

Just now, I built a project in a Subversion working copy and tried to push the resulting DLL, myproject.dll, to the repository. I got this error from TortoiseSVN:

Commit failed (details follow):
File '[path to myproject.dll]' is out of date
Item '[path to myproject.dll]' is out of date
You have to update your working copy first.

Okay, that makes sense. The version of myproject.dll which I have checked out is revision 9, and the most recent revision is revision 11. Subversion is asking me to update my DLL to revision 11 before committing.

Well, I don't want to. I don't care about the difference between revision 9 and revision 11; I just want my revision out there.

I do know one way to work around this:

  • Copy myproject.dll to myproject2.dll.
  • Update myproject.dll to revision 11 in order to make Subversion happy.
  • Rename myproject2.dll back to myproject.dll, overwriting revision 11.

Is there a more convenient way to do this, or is my method the best option available?

I'm not afraid of using the command line, but I also have TortoiseSVN, in case that provides another way to do things.

(I've seen the answers to How do you overcome the svn 'out of date' error?, but none of them seem to suggest a method that's easier than what I already have.)

1 Answer 1

1

This isn't the answer you want to hear, but Subversion wasn't intended for binaries. Your work-around is really the best way to do it.

Another solution is to go ahead with the svn up. You'll get a conflict. Then use svn resolve --accept mine-full conflicted_file.dll and you'll over-write the repository version with whatever you did. Just be careful that you don't overwrite your colleagues work.

$ svn update
Conflict discovered in 'foo.c'.
Select: (p) postpone, (df) diff-full, (e) edit,
        (mc) mine-conflict, (tc) theirs-conflict,
        (s) show all options: p
C    foo.c
Updated to revision 5.
Summary of conflicts:
  Text conflicts: 1
$ svn resolve --accept mine-full foo.c
Resolved conflicted state of 'foo.c'
$ 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.