SVN的文件夹链接太强大了!(目录链接,目录映射,svn:externals)

转自:http://blog.sina.com.cn/s/blog_63733daa0100y5hv.html

问题:

<wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)">我们的项目里,服务器脚本工程svn地址为:svn://server/script;配置文件地址为:svn://server/cfg。都是独立的仓库。有一天,对外发布人员觉得每次都Update两次很烦,说能否把类似这种目录都放在一个仓库里,只需要Update一次就可以了。</span><br style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)">是否所有资源、代码都用一个仓库就ok了呢?千万不要这么做,因为</span><br style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><wbr style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><span style="word-wrap:normal; word-break:normal; line-height:36px; color:rgb(73,73,73); font-family:simsun; text-align:left; background-color:rgb(246,246,246); font-size:24px">svn的效率很低!</span><span style="word-wrap:normal; word-break:normal; line-height:36px; color:rgb(73,73,73); font-family:simsun; text-align:left; background-color:rgb(246,246,246); font-size:24px"><strong><br><wbr></wbr></strong></span><span style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></span><span style="word-wrap:normal; word-break:normal; line-height:36px; color:rgb(73,73,73); font-family:simsun; text-align:left; background-color:rgb(246,246,246); font-size:24px"><span style="word-wrap:normal; word-break:normal; line-height:21px; font-size:14px">svn在管理代码这种文本文件(而且相比美术资源体积不大,文件不算多)的时候,下载、上传、查上传log速度还是可以接受的。我们已经做了多年的仓库依然能应付过来。<br><wbr><wbr><wbr>但是管理二进制文件的时候,速度实在是慢的令人发指,角色、场景这种容量、文件数比较夸张的目录,完全下载一次甚至可以用掉4个小时。随着时间流逝,历史记录越来越长,下载速度就越来越难以容忍了。<br><br><span style="word-wrap:normal; word-break:normal; font-weight:bold">解决方案:<br><wbr><wbr></wbr></wbr></span>把不同种类的资源放在不同的仓库里,具体怎么放可以由有经验的资源管理人员安排。然后,建立一个资源主干仓库。里面用文件夹链接的形式,存放各种资源。<br><br><wbr><wbr><wbr>资源管理员一旦设置好svn:externals属性之后,对用户来说,上传、下载都没有区别,就好像文件夹真的在主干仓库里一样。<br><wbr><wbr><wbr>等过了一段时间,例如半年,某一种资源太多需要清理的时候。管理员把现有资源干净的拷贝出来到新仓库(或者新目录),例如cha目录下所有文件拷贝到cha2目录,只要最后的结果文件不要svn信息。然后修改svn文件夹链接的地址。<br><wbr><wbr><wbr>修改好后,用户直接使用就ok了。达到了不影响其他人员的同时优化svn速度的目的。<br><br><wbr><wbr><wbr>(仅试验过,还没有在项目里实用,最后一步用户更新时可能会有冲突)<br><br><br><span style="word-wrap:normal; word-break:normal; font-weight:bold">TortoiseSVN操作方法</span>:右键-&gt;TortoiseSvn Properties-&gt;如下图编辑<br></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></span></span><img alt="" name="image_operate_84451326794601200" title="SVN的文件夹链接太强大了!(目录链接,目录映射,svn:externals)" style="margin-top:0px; margin-right:0px; margin-bottom:0px; margin-left:0px; padding-top:0px; padding-right:0px; padding-bottom:0px; padding-left:0px; border-top-width:0px; border-right-width:0px; border-bottom-width:0px; border-left-width:0px; border-style:initial; border-color:initial; list-style-type:none; list-style-position:initial; color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><a href="http://photo.blog.sina.com.cn/showpic.html#blogid=63733daa0100y5hv&amp;url=http://s14.sinaimg.cn/orignal/63733daatb6b67971e3bd" target="_blank" style="text-decoration:none; color:rgb(82,102,115); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"><img src="http://s14.sinaimg.cn/middle/63733daatb6b67971e3bd&amp;690" width="493" height="266" name="image_operate_82831326794730716" alt="SVN的文件夹链接太强大了!(目录链接,目录映射,svn:externals)" title="SVN的文件夹链接太强大了!(目录链接,目录映射,svn:externals)" style="margin-top:0px; margin-right:0px; margin-bottom:0px; margin-left:0px; padding-top:0px; padding-right:0px; padding-bottom:0px; padding-left:0px; border-top-width:0px; border-right-width:0px; border-bottom-width:0px; border-left-width:0px; border-style:initial; border-color:initial; list-style-type:none; list-style-position:initial"></a><br style="color:rgb(73,73,73); font-family:simsun; font-size:14px; line-height:21px; text-align:left; background-color:rgb(246,246,246)"></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值