Better solution to a clean index after a fast forward.
Better solution to a clean index after a fast forward.

If you checkout the tree object before updating the references,
it seems to fix the issues with a dirty index.y

MichaelBoselowitz/pygit2-examples