I'm trying to commit some work, but svn always fails and tells me that a file I modified is out of date. I tried updating first, that doesn't work. Cleanup doesn't work. If I revert the file, copy my changes over and try that, it still fails. It isn't just a particular file either, if I revert the whole thing back to a previous revision, and modify any file, this problem still occurs.
I am out of ideas. Anyone have anything?
Thanks.
Try creating a fresh checkout, then copying your changes to it. I had some inexplicable problems with TortoiseSVN too, and this was the only thing that helped.
If you can update your file the working copy seems to work properly.
Did you update the directory or only the file? I had situations when svn could not commit because the directory properties changed in the repository. An update on the directory solved this problem.
Another try is to use svn cleanup.
New checkout is the last resort.
Here's a common scenario I've seen cause a lot of people headaches. It's possible that you might be in this state:
The fatal mistake here was when the developer made a backup of dir 'foo', they also made a back up of all the hidden ".svn" directories nested inside foo.
So, the solution (in my experience), is to use tortoise svn's "export" capability to make a backup copy of foo. Tortoise svn Export will create a copy of the directory structure without any svn meta data (.svn dirs). This way, once you're back to step 3 and svn is happy, when you copy your backup back into your working copy directory, svn should be able to capture the changes correctly.
Then again, if it's only a single file you're creating a backup copy of, then, this won't help.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With