News for hackers. Stuff that matters.
Re: by Tomis02 on Tuesday November 22, 2022 @07:56AM (#33705237)
In case I wasn't clear, "git has an unintuitive and unfriendly CLI with bad defaults" when compared to hg.

Just compare the man pages! "git help clone" vs "hg help clone".

A random (trivial) example off the top of my head. When working with branches:

> git pull

> git switch another-branch

Your branch is behind 'origin/another-branch' by 2 commits, and can be fast-forwarded. (use "git pull" to update your local branch)

... why? I literally just pulled, why are you asking me to pull again? 99% of the people on the planet literally want the last version of that branch (provided there's no local changes leading to a conflict).

Compare with hg:

> hg pull

> hg update another-branch

Done.

I haven't worked with hg in a long time so I can't really provide an "absolute best example". All I can say is that, from memory, hg always got out of the way, and when I wanted to do something out of the ordinary I could either guess how to do it or it was easy to figure out from the manual.

With git, almost nothing's easy. It can become easy if you invest a lot of time in understanding how it works internally (which explains some of its CLI choices). But that to me is a sign of a bad tool. "all obscure things are a quick googling away" - why expose the user to obscure things to begin with?

There are no comments on this comment yet.