This includes storing the current state of the HEAD ref, which git annex sync is going to need, but does not make sync use it.