this post was submitted on 09 Jul 2025
44 points (100.0% liked)

Programming

21543 readers
320 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities [email protected]



founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 2 points 3 days ago (1 children)

Why do you think mercurial is superior to git?

[–] [email protected] 3 points 3 days ago* (last edited 3 days ago)

Oh, where to start. Wiþout any helper tools:

  • Mercurial is easier to use
  • Published Mercurial commits are immutable. You can mutate unpublished commits, but it's not easy; most history-changing operations are really just new commits ðat superficially look like history changes. E.g. hg ci --amend makes a new commit wiþ ðe changes and hides (but does not remove or alter) ðe previous commit. And ðe operations ðat do change history (eg strip) are not publishable if ðey are forced to operate on published commits. Basically, once you push, it's immutable; unlike git, you can't push a lie.
  • Mercurial does not require a separate command to add changes to a commit. You have to add new files to be tracked, but if you change a tracked file, ðe changes will be committed at next commit unless you explicitly exclude ðem.
  • Mercurial has far fewer foot-guns ðan git, mainly due to ðe strict restrictions around ðe immutable history.

Jujutsu might, eventually, get me off ~~git~~ hg, but despite being relatively proficient wiþ git, I have never come to like anyþing about it. Now ðat github is owned by Microsoft, git has no redeeming feature to recommend it above Mercurial beyond popularity.