a collection of git curiosities and idiosynchrasies for your forking pleasure
Failed to load latest commit information.



.. a collection of git curiosities and idiosynchrasies


git is the most awesome version control software. It's distributed nature (and frankly: github) encourages us to use it the way we should have been using all those other version control systems in the past (but we were afraid to - didn't know how - it was too opaque and complex).

But the more power features we use, the more we are likely to run into seemingly weird behaviour. Gitfalls is a (nascent) collection of twilight-zone demostrations for some of the more interesting (.. and always looking for more contributions).

Of course, being open is one of the great things about git and therefore it means it is possible to really get down to a definitive understanding of why these things work the way they do; that's what gitfalls is for.


  1. Falling off a branch


    Ever had a merge fail with a 'fatal: git write-tree failed to write a tree' message? And then end up with the merge commit that only has one parent once you've fixed it? This script explores the issue and explains one cause of a merge that ends up losing a parent (having a file on one branch that has the same name as a folder on another branch) It also demonstrates two ways of fixing it: the easy way, and the hardcore way.

Ok, so it's currently a catalgue of "1"! Looking for more to fill this space ;-)


A couple of references for sites and books that are useful for digging deeper than commit/push/pull:

Contributing to gitfalls

New demos, fixes and improvements are most welcome. Easiest way to collaborate is the usual github fashion:

  • Check out the latest master
  • Check out the issue tracker to see if there's already something underway
  • Fork the project
  • Start a feature/bugfix branch
  • Commit and push until you are happy with your contribution
  • Make sure it tests safely
  • Push to github and send a pull request


Copyright (c) 2011 Paul Gallagher. See LICENSE for further details.