设置 SVN (subvsersion) 来管理我们公司的文件,如何排除大文件进行版本控制

发布于 2024-08-27 04:26:33 字数 861 浏览 5 评论 0原文

我和另外两个人最近创办了我们自己的网络开发公司。我们每个人都在家工作,并决定为所有文件保留一个中央位置。这些文件包括Word文档、电子表格、客户文件、设计......等与我们公司有关的任何东西。我有一个相当稳定的互联网连接和一个 Windows 2008 服务器盒子坐在家里,所以我建立了一个颠覆存储库。

我们的文件存储库看起来像这样。

Clients
   Company A
       Design (photoshop files, wireframes, concepts)
       Documents ( logins, quotes, proposals etc)
       Site Backups
   Company B
       Design 
       Documents 
       Site Backups
Prospects
   Company C
   Company D
Our Company
   Our Website
   Documents (contract, operating procudres)

我的问题是关于设计文件的。我的设计师使用的 Photoshop 文件大小从 10mb 到 100mb 不等。我认为我们不需要保留这些文件的版本,因为这会以惊人的速度耗尽空间。 我如何控制哪些文件进行版本控制,以及哪些文件仅存储。我的想法是所有文档都需要进行版本控制,而除此之外的任何文件都不应该进行版本控制是。

任何帮助将不胜感激,谢谢!

编辑 我也很好奇这是否是一条路。我喜欢这个系统,因为它同时保留我所有文档的版本。另外,本质上我将在 3 个不同的位置有 3 个备份(3 个本地副本),因此无需备份。我不确定 svn 作为一个纯粹的巨大文件存储库将如何执行。

Me and two other guys recently started our own web development company. We each work from our homes and have decided we want to keep one central location for all of our files. These files include word documents, spreadsheets, client files, designs.. etc. Anything pertaining to our company. I have a pretty solid internet connection and a windows 2008 server box sitting at home so I set up a subversion repository.

Our file repository will look something like this.

Clients
   Company A
       Design (photoshop files, wireframes, concepts)
       Documents ( logins, quotes, proposals etc)
       Site Backups
   Company B
       Design 
       Documents 
       Site Backups
Prospects
   Company C
   Company D
Our Company
   Our Website
   Documents (contract, operating procudres)

My question is in regards to design files. The photoshop files that my designer works with range in sizes from 10mb to 100mb. I don't think we need to keep these files version-ed as this would eat up space incredibly fast. How do I go about controlling which files get version-ed, and which files are just stored. What I am thinking is that all documents need to be version-ed, and any files other then that should not be.

Any help would be appreciated, thanks!

Edit
I am also curious whether this is the way to go. I just like this system since it keeps version of all my documents and at the same time. Also essentially I will have 3 backups in 3 different locations (3 local copies) so no need for backing it up. I am unsure of how svn would perform as purely a huge file repository.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

殊姿 2024-09-03 04:26:33

使用 svn:ignore 属性。这是解释它的引用:

svn:ignore 属性包含一个
文件模式列表,其中某些
Subversion 操作将被忽略。
也许最常用的特殊
属性,它与
全局忽略运行时
配置选项(参见章节
称为“Config”)来过滤未版本化的
命令之外的文件和目录
svn status、svn add 和 svn import。

svn:ignore 背后的基本原理
属性很容易解释。
Subversion 并不假设每个
工作副本中的文件或子目录
目录用于版本
控制。资源必须明确
置于 Subversion 管理之下
使用 svn add 或 svn import
命令。结果,经常会出现
工作副本中的许多资源
没有版本控制。

它取自“Subversion 书”的属性部分


请注意,svn:ignore 属性可以通过文件名通配符(即*.exe)进行设置。您可以添加编程脚本(使用编程语言的挂钩或 SVN 绑定)来指定其他规则 - 即忽略所有超过 100MB 的文件。然而,这可能有些危险。选择权在你。

Use the svn:ignore property. Here's a quote explaining it:

The svn:ignore property contains a
list of file patterns which certain
Subversion operations will ignore.
Perhaps the most commonly used special
property, it works in conjunction with
the global-ignores run-time
configuration option (see the section
called “Config”) to filter unversioned
files and directories out of commands
svn status, svn add, and svn import.

The rationale behind the svn:ignore
property is easily explained.
Subversion does not assume that every
file or subdirectory in a working copy
directory is intended for version
control. Resources must be explicitly
placed under Subversion's management
using the svn add or svn import
commands. As a result, there are often
many resources in a working copy that
are not versioned.

It's taken from the "Subversion book", the section on properties.


Note that the svn:ignore property can be set by filename wildcards (i.e. *.exe). You can add programmatic scripting (using hooks or SVN bindings for a programming language) to specify other rules - i.e. all files above 100MB are ignored. However, this may be somewhat dangerous. The choice is yours.

不爱素颜 2024-09-03 04:26:33

与您可能认为的相反,Subversion 实际上非常适合存储二进制文件,甚至可以在版本之间进行二进制比较。

在您决定是否对文件进行版本控制时,不应考虑文件大小。是否需要版本控制应该是值得关注的问题。其他任何事情都只是搬起石头砸自己的脚。

Contrary to what you may believe, Subversion is actually very well suited to store binary files, and even does binary diffing between versions.

Filesize should not be a concern in your decision to version files or not. Whether you need version control should be the concern. Anything else is just shooting yourself in the foot.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文