Alexandre Julliard <julliard@xxxxxxxxxx> writes: > The previous check caused the hook to reject as unannotated any tag > whose SHA1 starts with a zero. > > Signed-off-by: Alexandre Julliard <julliard@xxxxxxxxxx> > --- > templates/hooks--update | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/templates/hooks--update b/templates/hooks--update > index 9d3795c..d8c7626 100644 > --- a/templates/hooks--update > +++ b/templates/hooks--update > @@ -42,7 +42,7 @@ fi > > # --- Check types > # if $newrev is 0000...0000, it's a commit to delete a branch > -if [ -z "${newrev##0*}" ]; then > +if [ "$newrev" = "0000000000000000000000000000000000000000" ]; then > newrev_type=commit The first intention could have been expressed as case "${newrev}" in *[^0]*) ;; *) newrev_type=commit;esac But your version seems clearer. -- David Kastrup, Kriemhildstr. 15, 44793 Bochum - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html