我正在开始一个新的分布式项目。我应该使用SVN还是Git,为什么?


当前回答

你必须使用DVCS,它就像源代码管理的一个量子飞跃。就我个人而言,我使用Monotone和它加速的开发时间没有结束。我们在Windows、Linux和Mac上使用它,它非常稳定。我甚至让buildbot在每个平台上进行每晚的项目构建。

分布式DVCS通常意味着您将创建一个中央服务器,仅供人们推送更改。

其他回答

Git在Windows下还不受本地支持。它针对Posix系统进行了优化。然而,运行Cygwin或MinGW可以让你成功运行Git。

现在我更喜欢Git而不是SVN,但是如果你来自CVS, SVN的土地,它需要一段时间才能超过阈值。

SVN的2个主要优点很少被提及:

Large file support. In addition to code, I use SVN to manage my home directory. SVN is the only VCS (distributed or not) that doesn't choke on my TrueCrypt files (please correct me if there's another VCS that handles 500MB+ files effectively). This is because diff comparisons are streamed (this is a very essential point). Rsync is unacceptable because it's not 2-way. Partial repository (subdir) checkout/checkin. Mercurial and bzr don't support this, and git's support is limited. This is bad in a team environment, but invaluable if I want to check something out on another computer from my home dir.

只是我的经验。

If your team is already familiar with version and source control softwares like cvs or svn, then, for a simple and small project (such as you claim it is), I would recommend you stick to SVN. I am really comfortable with svn, but for the current e-commerce project I am doing on django, I decided to work on git (I am using git in svn-mode, that is, with a centralised repo that I push to and pull from in order to collaborate with at least one other developer). The other developer is comfortable with SVN, and while others' experiences may differ, both of us are having a really bad time embracing git for this small project. (We are both hardcore Linux users, if it matters at all.)

当然,你的里程可能会有所不同。

你必须使用DVCS,它就像源代码管理的一个量子飞跃。就我个人而言,我使用Monotone和它加速的开发时间没有结束。我们在Windows、Linux和Mac上使用它,它非常稳定。我甚至让buildbot在每个平台上进行每晚的项目构建。

分布式DVCS通常意味着您将创建一个中央服务器,仅供人们推送更改。

我从来没有理解过“git在Windows上不好”这个概念;我只在Windows下开发,git从来没有遇到过任何问题。

我绝对推荐git而不是subversion;它只是更加通用,并且允许“离线开发”,这是subversion永远无法做到的。它可以在几乎所有可以想象到的平台上使用,并且拥有比你可能使用过的更多的功能。