hooks-available: avoid some errors with empty repositories
authorAntonio Ospite <ao2@ao2.it>
Thu, 13 Dec 2018 23:15:05 +0000 (00:15 +0100)
committerAntonio Ospite <ao2@ao2.it>
Mon, 17 Dec 2018 09:37:45 +0000 (10:37 +0100)
When entering a repository which has just been created the HEAD
reference does not exist yet  and "git read-tree -mu HEAD" would
complain loudly about that, giving a confusing error to users.

Avoid the error by checking the validity of HEAD before updating the
working tree.


No differences found