减少.svn文件夹的大小 [英] Reducing the size of the .svn folder

查看:1373
本文介绍了减少.svn文件夹的大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我们的项目中,我们决定通过使用预构建的二进制文件来减少构建时间.每周/每月,我们创建一个稳定的发行版并将其提交到存储库.构建使用这些二进制文件,而不是从源代码构建所有内容.

In our project we made the decision to reduce the build time by using pre-built binaries. Weekly/monthly we create a stable release and commit it to the repository. The build uses these binaries instead of building everything from source.

对于构建速度来说,这太棒了.但是,毫不奇怪,它确实增加了SVN结帐的大小.目前,我们的后备箱容量约为22GB.我意识到这不是Subversion的预期用途.但是我们目前没有其他选择.

For build speed this is fantastic. But, unsurprisingly, it really bulks up the SVN checkout size. Our trunk currently sits at ~22 GB. I realize this is not the intended usage of Subversion. But we don't have an alternative at the moment.

但是我想改善当前的状况. .svn文件夹对磁盘上干线的大小有很大的贡献.二进制文件更新后,似乎在.svn文件夹中保留了几个基础.也就是说,如果二进制文件是4 GB,则.svn中有一个副本.如果已更新,则.svn文件夹将保留原始基础以及新基础,并且该文件的最大容量为8GB.

But I'd like to improve the current situation. The .svn folder makes a big contribution to the size of trunk on disk. When the binaries are updated, it seems to keep several bases in the .svn folder. That is, if a binary is 4 GB there is a copy in the .svn. If it's updated then the .svn folder holds the original base plus the new base and bulks up to 8 GB for that one file.

是否可以告诉Subversion不在某些文件的.svn文件夹中保留基准?通过Google,我发现了一个类似的问题, 如何减小.svn文件夹的大小? .

Is it possible to tell Subversion not to keep a base in the .svn folder for certain files? Through google I found a similar question, How to decrease .svn folder size?.

西蒙收到的答案是

  • 使用部分签出(对我而言,这对我来说不起作用)
  • 这还不是Subversion的功能
  • 已进行了讨论,但至少在Subversion 1.8之前不会成为功能

幸运的是,subversion 1.8已发布.是否添加了此功能?

Luckily for me subversion 1.8 has been released. Was this feature added?

我没有在发行说明中注意到它.尽管减少目录和财产存储"看起来很有希望.

I did not notice it in the release notes. Though "Directory and property storage reduction" looks promising.

推荐答案

目前还无法摆脱存储原始数据的需要.已经讨论过了,但是实际上这不是一个容易解决的问题,因为有很多不同的用例情况都可以通过有选择地删除它们来呈现.

There's no way to get rid of the need to store pristines at this point. It's been talked about but it's actually not an easy problem to solve because there's so many different use case situations that would be presented by removing them optionally.

对于1.7,原始存储已更改,在某些情况下,您实际上可能会发现情况比1.7之前的情况还要糟糕.现在,雌激素被存储在由原始哈希表命名的文件中.因此,如果您有多个相同的文件,则不会存储重复的原始文件.但是,我们也不再清理原始数据.因此,他们只是继续建立.您可以使用svn cleanup触发删除未使用的原始记录.

With 1.7 the pristine storage was changed and in some cases you may actually see the situation as worse than before 1.7. Pristines are now stored in files named by the hash of the pristine. So if you have multiple identical files you won't have duplicate pristines stored. However, we also don't cleanup pristines anymore. So they just continue to build up. You can trigger unused pristines to be removed with svn cleanup.

保留未使用的原始数据是很重要的,如果您在分支之间切换,我们将不再需要下载1.8中已经具有原始数据的内容.

There is a point to keeping unused pristines around, if you're switching between branches we no longer have to download things that you already have the pristine for in 1.8.

这篇关于减少.svn文件夹的大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆