2024-04-12 10:00:04

SVN仍然存在冲突?

如何将这个目录从冲突中删除?我不在乎是用“他们的”还是“我的”或其他什么来解决……

PS C:\Users\Mark\Desktop\myproject> svn ci -m "gr"
svn: Commit failed (details follow):
svn: Aborting commit: 'C:\Users\Mark\Desktop\myproject\addons' remains in conflict

PS C:\Users\Mark\Desktop\myproject> svn resolve --accept working C:\Users\Mark\Desktop\myproject\addons
Resolved conflicted state of 'C:\Users\Mark\Desktop\myproject\addons'

PS C:\Users\Mark\Desktop\myproject> svn ci -m "grr"
svn: Commit failed (details follow):
svn: Commit item 'addons' has copy flag but an invalid revision

PS C:\Users\Mark\Desktop\myproject> svn update
   C addons
svn: Can't move 'addons\debug_toolbar\templates\debug_toolbar\.svn\tmp\entries' to 'addons\debug_toolbar\templates\debug
_toolbar\.svn\entries': The file or directory is corrupted and unreadable.

PS C:\Users\Mark\Desktop\myproject> svn cleanup

PS C:\Users\Mark\Desktop\myproject> svn update
Skipped 'addons'
At revision 51.
Summary of conflicts:
  Skipped paths: 1

PS C:\Users\Mark\Desktop\myproject> svn ci -m "grrr"
svn: Commit failed (details follow):
svn: Aborting commit: 'C:\Users\Mark\Desktop\myproject\addons' remains in conflict

当前回答

我在linux上也有同样的问题,但我无法用公认的答案解决它。我能够解决它通过使用cd到正确的文件夹,然后执行:

svn remove --force filename  
syn resolve --accept=working filename  
svn up

这是所有。

其他回答

如果您在解决问题时遇到了麻烦(像我一样),并且由于对资源进行了许多更改而无法删除和更新资源,再加上您使用的是eclipse subversion而不是本机客户端,请遵循以下步骤:

make a copy of your entire project dir perform team>disconnect within eclipse, and choose to delete the svn metadata then choose team>share project, and point to the very same folder that your project resides in choose yes, and commit everything (you may want to exclude some very local resources, like configuration files) if you have deleted or moved some resources prior to your first commit trial, delete those old resources (they should have doubled up, one in old location, one in new) and commit those deletions.

你就完成了。

我也有类似的问题,这就是它是如何解决的

xyz@ip:~/formsProject_SVN$ svn resolved formsProj/templates/search

解决了formsProj/templates/search的冲突状态

现在更新你的项目

xyz@ip:~/formsProject_SVN$ svn update

更新“。”:

选择:(mc)保留受影响的本地移动, (r)标记解决(打破移动),(p)推迟, (q)退出解析,(h)帮助:r(选择“r”选项解析)

解决了formsProj/templates/search的冲突状态

冲突总结: 树冲突:0个剩余(1个已经解决)

为了使用命令行消除冲突,我使用以下命令

svn revert "location of conflict folder" -R
svn cleanup
svn update

用于恢复当前目录

svn revert . -R

下面还有一个解决方案,

如果整个文件夹被删除,SVNis抛出错误“admin file . SVNis missing”,将使用以下方法将冲突解决到工作状态。

svn resolve --accept working "file / directory name "

对于我只恢复-深度无穷大选项固定 Svn目录存在冲突问题:

svn revert --depth infinity "<directory name>"
svn update "<directory name>"