[gh] reformat (!) and add resethook command

This is a helper for the case where repositories have a single hook.
This command list existing hooks, remove them and register a new one.