你使用分布式版本控制吗? [英] Do you use distributed version control?

查看:26
本文介绍了你使用分布式版本控制吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想听听使用分布式版本控制(又名分布式修订控制、去中心化版本控制)的人的意见,以及他们是如何找到它的.你在用什么,Mercurial、Darcs、Git、Bazaar?你还在用吗?如果您过去使用过客户端/服务器 rcs,您是否发现它更好、更糟或只是不同?你能告诉我什么会让我跟上潮流?或者就此而言,我也有兴趣听取有负面经历的人的意见.

I'd like to hear from people who are using distributed version control (aka distributed revision control, decentralized version control) and how they are finding it. What are you using, Mercurial, Darcs, Git, Bazaar? Are you still using it? If you've used client/server rcs in the past, are you finding it better, worse or just different? What could you tell me that would get me to jump on the bandwagon? Or jump off for that matter, I'd be interested to hear from people with negative experiences as well.

我目前正在考虑更换我们当前的源代码控制系统 (Subversion),这是解决这个问题的动力.

I'm currently looking at replacing our current source control system (Subversion) which is the impetus for this question.

我对与其他国家/地区的同事一起使用它的人特别感兴趣,在这些国家/地区,您的机器可能不会同时打开,并且您的连接速度很慢.

I'd be especially interested in anyone who's used it with co-workers in other countries, where your machines may not be on at the same time, and your connection is very slow.

如果您不确定分布式版本控制是什么,这里有几篇文章:

If you're not sure what distributed version control is, here are a couple articles:

分布式版本控制简介

维基百科条目

推荐答案

我一直在工作和我自己的个人项目中使用 Mercurial,我对它非常满意.我看到的优点是:

I've been using Mercurial both at work and in my own personal projects, and I am really happy with it. The advantages I see are:

  1. 本地版本控制. 有时我正在处理某些事情,我想保留版本历史记录,但我还没有准备好将其推送到中央存储库.使用分布式 VCS,我可以只提交到我的本地存储库,直到它准备好,而无需分支.这样,如果其他人进行了我需要的更改,我仍然可以获取它们并将它们集成到我的代码中.准备就绪后,我会将其推送到服务器.
  2. 更少的合并冲突.它们仍然发生,但它们似乎不那么频繁,风险也更小,因为所有代码都签入了我的本地存储库,所以即使我搞砸了合并,我可以随时备份并再次执行.
  3. 将存储库作为分支分开.如果我有几个开发向量同时运行,我可以制作我的存储库的多个克隆并独立开发每个功能.这样,如果某些东西报废或滑落,我就不必拉出碎片.当它们准备就绪时,我会将它们合并在一起.
  4. 速度.使用 Mercurial 的速度要快得多,主要是因为您的大部分常见操作都是在本地进行的.
  1. Local version control. Sometimes I'm working on something, and I want to keep a version history on it, but I'm not ready to push it to the central repositories. With distributed VCS, I can just commit to my local repo until it's ready, without branching. That way, if other people make changes that I need, I can still get them and integrate them into my code. When I'm ready, I push it out to the servers.
  2. Fewer merge conflicts. They still happen, but they seem to be less frequent, and are less of a risk, because all the code is checked in to my local repo, so even if I botch the merge, I can always back up and do it again.
  3. Separate repos as branches. If I have a couple development vectors running at the same time, I can just make several clones of my repo and develop each feature independently. That way, if something gets scrapped or slipped, I don't have to pull pieces out. When they're ready to go, I just merge them together.
  4. Speed. Mercurial is much faster to work with, mostly because most of your common operations are local.

当然,就像任何新系统一样,在转换过程中也有一些痛苦.您必须以与使用 SVN 时不同的方式来考虑版本控制,但总的来说,我认为这是非常值得的.

Of course, like any new system, there was some pain during the transition. You have to think about version control differently than you did when you were using SVN, but overall I think it's very much worth it.

这篇关于你使用分布式版本控制吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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