Repository.xs: Added detach_head()

* head() and detach_head() now take an optional reflog message to be used
02-commit.t: Added tests for detach_head()
Changes: update