Subversion Update Issue

匆匆过客 提交于 2019-12-22 10:45:25

问题


I'm getting the following error when I try to update my repository. Can someone explain what it means?

Command: Update
Error: URL
Error: 'http://mysvn/foo'
Error: of existing directory
Error: 'C:\SVN\MyProj\NinjectModules\Models' does not match
Error: expected URL 'http://mysvn/foo/NinjectModules/Models'
Finished!:


回答1:


This kind of error message is usually associated with letter casing errors in the svn repository. Perhaps your svn is installed on a Linux machine and there you have two identical folders:

(..)/mysvn/foo
(..)/MySVN/Foo

And initially SVN checks out MySVN/Foo and it doesn't find the \NinjectModules\Models folder because it is in /mysvn/foo location




回答2:


It is not always a case problem

I encountered this error message due to improper directory moving that scrambled the svn data. The way I fixed it was to delete the working copy directory and then svn update that directory.




回答3:


Another reason might be migration from including some files with svn:externals property to actually adding the files to your repository.

That is, when between two updates of your working copy someone does following:

#svn up removes local copies of external resources when svn:externals is deleted
#so we need a backup
cp -R library/resource /backup
svn propdel 'svn:externals' library
svn up
cp -R /backup/resource library
svn add library/resource
svn commit -m "this will break other working copies, but we have the resource in our repo now"

When you try to svn update your wc, you will get following message:

svn: URL 'svn://path.to/external/resource' of existing directory 
'library/resource' does not match expected URL 'svn://my.own.repository/library/resource'

In such case the solution is as usual - remove the library directory of the working copy and do svn up to restore it in its current state.

Remeber to back up your local changes somewhere



来源:https://stackoverflow.com/questions/6834155/subversion-update-issue

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!