Mercurial basics

From Exterior Memory
Revision as of 17:49, 10 March 2018 by MacFreek (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Mercurial is version control software, similar to Git.

There are two main differences:

Mercurial does not allow changing of the history
Well, it does (if you enable one of the Mercurial extension), but it makes this really hard. Git on the hand, doesn't stop you from playing around with `git rebase`. While some may say Git is more powerful, Mercurial is more forgiving for novice users.
Git branches are called Mercurial bookmarks
Mercurial does have the notion of named branches, which are similar to bookmarks, but with the difference that every change made to that branch is tagged with the name of that branch. The advantage is that it easier to see what happened in the history tree: Mercurial branches show the name of that branch. In Git you have to rely on the quality if the commit messages. Note that you can't delete branches in Mercurial, but you can close them, meaning that they won't be visible by default. Previously, it was not possible to push bookmarks to remote repositories, but this is possible since Mercurial 1.6.