How do you overcome the svn 'out of date' error?

前端 未结 30 2085
鱼传尺愫
鱼传尺愫 2020-12-12 08:51

I\'ve been attempting move a directory structure from one location to another in Subversion, but I get an Item \'*\' is out of date commit error.

I ha

相关标签:
30条回答
  • 2020-12-12 09:34

    I believe this problem is coming from the .svn file. It's either incorrect in the old parent, the new parent or the old one. I would try reverting back to your starting point. Use an export to get a clean copy of the folder. Move the clean copy to the new location, and use an add and delete to do the move. That's manually doing what SVN does, but it might work.

    0 讨论(0)
  • 2020-12-12 09:36

    If you're using the github svn bridge, it is likely because something changed on github's side of things. The solution is simple, you just have to run svn switch, which lets it properly find itself, then update and everything will work. Just run the following from the root of your checkout

    svn info | grep Relative 
    svn switch path_from_previous_command
    svn update
    

    or

    svn switch `svn info | grep Relative | sed 's_.*: __'`
    svn update
    

    The basis for this solution comes from Lee Preimesberger's blog

    0 讨论(0)
  • 2020-12-12 09:37

    To solve, I needed to revert the file with problem, and update my working copy, and later I modified the file again and after these steps the error didn't happened anymore.

    0 讨论(0)
  • 2020-12-12 09:38

    Thank you. That just resolved it for me. svn update --force /path to filename/

    If your recent file in the local directory is the same, there are no prompts. If the file is different, it prompts for tf, mf etc... chosing mf (mine full) insures nothing is overwritten and I could commit when done.

    Jay CompuMatter

    0 讨论(0)
  • 2020-12-12 09:38

    If once solved a similar issue by simply checking out a new working copy and replacing the .svn directory throwing the commit errors with this newly checked out one. The reason in my case was that after a repository corruption and restore from a backup the working copy was pointing towards a revision that didn't exist in the restored repository. Also got "item out of date" errors. Updating the working copy before commit didn't solve this but replacing the .svn as described above did.

    0 讨论(0)
  • 2020-12-12 09:38

    I did this and it worked for me:
    1. Take a back-up of your file. You can simply copy your code to a text file.
    2. Right Click the file you want to commit >> Team >> Show History. 3. In "Show History" Panel you will see all the revisions of that file. Right click on latest revision of the file >> Get Revision: It will override your local changes.
    4. Now, merge your code with the latest file with the back-up file (step#1).
    5. Synchronise and Commit the newly merged file.

    0 讨论(0)
提交回复
热议问题