Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> If I suddenly find out that I forgot to add something, I don't have to amend, I don't have to modify the commit, I can just stage my change and press `c e` - "extend". It will quietly add it to my previous commit.

Unless I’ve thoroughly misunderstood you, what you’re saying is that “c e” is equivalent to “git commit --amend”. This sounds suspiciously like “amend[ing]”.

Sure, git’s user interface is somewhere between mediocre and abysmal, but it’s not really clear to me that “c e” is a vast improvement.

I say this as a former org-mode user and even one-time contributor. Eventually I decided that the sheer number of magic incantations I had to remember to do anything useful wasn’t worth it.



It's actually `git commit --amend --no-edit`, but yes, it's basically "just" a shortcut. Count the keystrokes, though. If you spend much time working with git it's a huge win.

Of course you could do something similar with shell aliases or reverse search, but then there are other switches and flags that you need occasionally, etc. And it's sooo much more convenient to have everything in one place right in your editor. It's almost unfair how much faster I can get stuff done than folks who don't use it ;)

Magit isn't hype, it's as good as everyone says it is. You just have to try it.


> Magit isn't hype, it's as good as everyone says it is. You just have to try it.

Exactly! People switch to Emacs because someone shows them Magit. Even though they either don't care much about Emacs or it intimidates them.

I myself used IntelliJ for a long time. I have to say, IntelliJ has a superb Git integration. For a very long time I didn't want to switch to Emacs, because I didn't want to lose that. I thought Emacs's Magit thing just not good enough - it can't be, IntelliJ's seemed to be just unbeatable. Oh boy, how wrong I was. Wasted years of my life being ignorant.


If you spend much time with Git, you create aliases.

Not saying that Magit isn't worth it (never used it), but it's not a fair comparison. I don't `git commit --amend --no-edit`: I `git amend` to edit the last commit, `git amend HASH` to edit any commit, `git amend -i` to pick a commit to edit in a searchable list with preview of their content.


> git amend HASH

That's 9 characters plus the effort of finding and copy/pasting the hash. With magit it's two characters and you just focus on the hash in question.

> `git amend -i` to pick a commit to edit in a searchable list with preview of their content

That's cool! Still a lot more typing than with Magit, which also has a searchable list with content previews ;)

I'm happy that you've found ways to optimize your workflow, but seriously, Magit is still faster.


"If you spend much time solving equations you eventually get a knack for it. Not saying that calculators not worth it (never used one), I just don't think they are that much useful. Why do you need to carry something with you when you can do calculus and solve linear and quadratic equations in your head?"

That's how your argumentation sounds to me.


> Eventually I decided that the sheer number of magic incantations I had to remember to do anything useful wasn’t worth it

Isn't that the point of Magit?

People who never tried Magit often say either of these two things:

- "I'm already an expert in Git, I'm fine with the command line", or

- "Git is confusing already, I don't want to learn yet another thing"

The main point about Magit (unlike many other Git GUIs) - is to help you discover Git features, and allow you to do your work in a very efficient and simple workflow. However, it would do so without hiding Git mechanics from the user. Anytime you can check what the actual Git command gets executed.

Magit doesn't liberate you from learning Git internals, but at the same time it doesn't overwhelm you with tons of different command-line switches. You don't have to memorize anything, the reference for all the commands is always available to you.

I believe, I have become a Git ninja because of Magit. Without it, who knows, maybe I would never learn many features of Git.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: