与具有大型存储库的 SVN 持续集成
所以我们有一个 SVN 存储库,其中包含一个相当大的项目,第一次需要大约一个小时才能拉下来。我们已经设置了与 CruiseControl 的持续集成,并在提交时触发它。由于拉取时间较长,我们不会删除构建机器上的构建目录,而是仅发出 svn update 命令来获取最新版本。
添加、更新和删除已签入 SVN 的文件工作正常,但我们遇到的问题是在构建过程中生成文件。这些生成的文件永远不应该被签入,但我想在构建之间清除它们。
本质上,我想要一个 svn update 命令:
- 将目录更新到当前版本。
- 删除所有不受源代码控制的文件。
我只是错过了一些东西还是没有 SVN 命令?
更新: 我在一台windows机器上。我知道我可以使用 cygwin 或其他方法来完成此操作,但我很好奇是否有 SVN 或 CC.Net 功能可以实现此目的。
So we have a SVN repository which houses a rather large project that takes about an hour to pull down for the first time. We've setup continuous integration with CruiseControl and we have it triggered on commits. Because of the long pull time we don't delete the build directory on the build machine and instead just issue a svn update command to get the latest version.
The works fine on adding, updating, and removing files which have been checked into SVN, but the issue we have is that during the build process files are generated. Those generated files should never be checked in but I would like to clean them out between builds.
Essentially, I'd like a svn update command that:
- Updated the directory to the current version.
- Removes all files not under source control.
Am I just missing something or is there no SVN command for this?
Update:
I am on a windows machine. I'm aware that I could do this with cygwin or other methods, but I'm curious if there is a SVN or CC.Net feature for this.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
查看这篇博客文章(和评论线程),了解如何删除不在 subversion 中的文件有多种方法。如果您习惯使用 git,我认为切换到 git-svn 作为您的客户端也可能允许您处理清理工作。
Check out this blog post (and comment thread) on how to Remove files that are not in subversion for several methods. If you're comfortable using git, I think switching to git-svn as your client might also allow you to handle the cleanup.
您可以运行 svn update 命令,然后删除未版本化的文件,如此处。
任何一个都可以。哦,也许你在 Windows 盒子上?你能澄清一下吗?
You can run the svn update command and subsequently removed the unversioned files as mentioned here.
either one would work. Oh maybe you are on a windows box? Could you clarify?