It is possible to completely remove a file from my SVN repository?

陌路散爱 提交于 2019-12-01 15:12:20
ryansstack

http://subversion.apache.org/faq.html#removal

you can't, quickly, but there is a way

I've looked at doing something similar, and fundamentally Subversion is set up so that you can't simply delete something like that.

But since you are already backing up the database, you should check this out. What I ended up doing was dumping my repository, filtering it, and then loading it into a new repository. Of course, I was already doing the dump / filter / load cycle for other reasons, so a little bit of extra filtering didn't add much work. If you're already doing a backup, you can backup your current repo (I assume you're doing a dump, or multiple incremental dumps for that), filter that particular revision out using svndumpfilter, and reload from the backup.

EDIT: Tigris officially has an issue 516 on this. The "svn obliterate" command is planned, but it isn't implemented yet.

As far as I know, once a file is committed in svn, there is no functionality in svn for undoing that. You can remove the file from the directory and commit the directory, but that will only make the file not being part of the latest revision of the directory; the committed revision is still in there. Usually I find that a good thing, but of course there are cases (like yours) where it may be less desirable.

We ran into the same problem. My SVN server admin tells me this cannot be done. The only way you can do it is start a new repository and archive the old one to disk or whatever.

Don't make any changes to the file, esp. if it's a binary file, because then I believe SVN stores multiple copies of it.

it is not possible to undo a committed file from svn.

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