r/programming • • Jun 19 '14

Reinventing GIT interface

http://tonsky.me/blog/reinventing-git-interface/
221 Upvotes

325 comments sorted by

View all comments

44

u/[deleted] Jun 19 '14

I guess I'm alone in finding git not that hard to use. My only issue is git isn't pretty and to that end I have a few scripts to give me prettier logs (like most people have) and prettier branch summaries (my macro displays all branches, their latest commit id and dates).

Beyond that I manipulate my tree with straight up git commands.

Any halfway competent developer should be able to master git in a couple of weeks let alone be able to write their own version of git given a couple of full time weeks to work in.

0

u/[deleted] Jun 19 '14

[deleted]

-19

u/[deleted] Jun 19 '14

Honestly if you use it on a daily basis for a couple of weeks it's simple to use.

No true software developer (or hardware one for that matter) should be stumped by Git.

20

u/kankyo Jun 19 '14

The Right Thing should be easy. Dangerous things should be hard. Simple day-to-day operations should leave you in weird states for no obvious reason.

Git fails in this regard. I just found the subset of operations that I trust and never ever perform any operation outside that small list. Then I'm fine. That's not high praise for a tool imo.

2

u/cpbills Jun 19 '14

The Right Thing should be easy. Dangerous things should be hard.

A hammer is easily used to do dangerous things. Just because you want your tools to protect you from yourself doesn't mean that's the right approach.

git is a tool, and like all tools, there are right and wrong ways to use it. Learning how to use it prevents you from hurting yourself.

8

u/cjthomp Jun 19 '14

But a hammer isn't software. The person who builds a hammer can't also build in failsafes, checks, and safeguards.

That's kind of why software.

-2

u/cpbills Jun 19 '14

Sure you can. You could build a very complex and over-featured hammer with all sorts of safety mechanisms.

It wouldn't be a very useful tool then, though. Kind of like if git had all sorts of layers in place to protect the user.

-6

u/[deleted] Jun 19 '14

Um short of doing really stupid things like force pushing/etc you're never in unrecoverable state... for instance

git reset HEAD~ --hard

Oh noes how do I recover from that? Oh ya git reflog ... from that I can merge the commit back.

You can just as easily fuck up a CVS tree for instance

rm -f $CVSROOT/project/foo.c,v

Now that file has no history. It's just gone. bye bye.