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

New users find Git difficult because it has extensive hidden state. The effect of "git commit/diff/reset" is completely dependent on the invisible state of the stage/branch/history DAG.

A competent user always knows what "git status" will output. But novices don't even understand which hidden state they must keep track of.



One thing I've found helpful is adding git status information to my command prompt. (For this, I use oh-my-zsh.) I always know what branch I'm on, and whether it's dirty or not.

I still need to 'git status' (which I've aliased to 'gs') sometimes but more frequently I get what I need without it.


By 'hidden state' do you mean that Git doesn't easily show the user where they are in the process? Is something like sourcetree a good solution?


Exactly -- I've found SourceTree and the Visual Git Reference (http://marklodato.github.io/visual-git-guide/index-en.html) very useful to teach beginners.


It's an education gap. A step-by-step site with shell and corresponding diagrams of high-level behavior might help.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

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

Search: