9

Lately I've been searching for the best source control technologies for my work projects. I've been a subversion user for a while, but heard more and more about git. So I checked it out, and I very much liked the fact that it allows you to easily put your projects under source control, even offline, when you don't have access to a server. However in multiple programmer environments (for instance at work) the idea of a central server still has its benefits. That's when I came across Mercurial, this seems to me to be the best of both worlds, since you can just put your project under source control offline, you can pull push to other people if they put up a webserver, but you can also use a central server to push to and pull from.. Combine that with the fact that something like bitbucket.com gives you the chance to start a private free repository online..

So am I right in my thinking, or are there some important subtleties with these source control systems in a work environment that I fail to grasp?

Falx
  • 185
  • 8
  • See http://stackoverflow.com/questions/35837/what-is-the-difference-between-mercurial-and-git – Adam Ralph Jun 01 '11 at 06:13
  • See http://stackoverflow.com/questions/77485/what-are-the-relative-strengths-and-weaknesses-of-git-mercurial-and-bazaar – Bruce Jun 01 '11 at 06:24

4 Answers4

10

You are missing something - git also allows you to have a central server. And github provides the same sort of facilities as bitbucket. Having said that, I think that that Mercurial is a better choice than git for someone starting out in version control, as it is somewhat easier to use, less complex and (for new users at least) its documentation is less intimidating.

Also, you don't say what platform(s) you use, but currently the Mercurial user interface on Windows has a distinct edge over git.

  • Thank you, I will take that into account about git ang github. The platform I mainly use to develop on is windows, and the occasional linux. But more often windows. – Falx Jun 01 '11 at 07:19
  • 1
    Not built-in, but [SmartGit](http://www.syntevo.com/smartgit) is a pretty swish UI for git on Windows. Free for personal use, and licenses are relatively cheap. (No affiliation) – Benjol Jun 01 '11 at 08:30
  • I believe Mercurial's "Windows advantage" is not really the case anymore. Certainly was true maybe as little as a year ago, but the Windows client options have expanded a lot recently. – Dan Ray Jun 01 '11 at 12:10
  • @Dan Dunno. Last time I looked at TortotiseGit was about 6 months ago, and it was buggy as hell then. There are also problems with MinGW Git (or whatever it is called) in that the bash shell is ultra slow on Win 7 unless you run as an administrator (which I do). –  Jun 01 '11 at 16:49
3

As Neil already mentioned there is nothing stopping you in having a central server for git.

In my experience mercurial is easier to grasp than git, and getting starting is very easy. Some argue that git is more powerful. Whether that is actually true I leave for you to discover yourself.

What you should take into consideration is that neither git or mercurial have the same type of user authentication as SVN. There are however multiple ways to solve that problem (using SSH, HTTP, ...)

Hannes Ovrén
  • 21,229
  • 9
  • 65
  • 75
  • Thanks for your answer, I'm aware that asking for the better of the two/three is somewhat of an endless discussion-road, and that I probably will have to discover that on my own. But the pointers I got in this thread made me pay attention on features and details that otherwise I wouldn't have. (like the user authentication for instance) – Falx Jun 01 '11 at 07:17
2

To answer your question, I believe so.

I use mercurial for all my mercurial, git and subversion repository access. I use a mercurial extension called hg-git http://hg-git.github.com/ to work with git repositories; mainly on github. Mercurial has a few ways to work with subverion, but ultimately I have converted those svn repos and not needed to do anything more.

As far mercurial alone being great, it is. But mostly it's great because dvcs is great. If you can, use them both (git, hg) for a while and try to best understand them. You can't go wrong with choosing git or hg.

  • +1 for mentioning hg-git. I agree that dvcs are great, but I'd still recommend hg over git for a new switcher because its more accessible (it was for me). – Peer Stritzinger Jun 02 '11 at 08:56
1

Well, I would say you should check this out. It is getting used by some really big projects like OpenJDK, Nuxeo, NetBeans, OpenOffice,OpenSolaris, jMaps, RabbitMQ etc. I have been using Bitbucket/Mercurail from last few years and I am extremely happy with it. Sapan

Awais Qarni
  • 17,492
  • 24
  • 75
  • 137
Sap
  • 5,197
  • 8
  • 59
  • 101