accumulo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christopher Tubbs (JIRA)" <>
Subject [jira] [Commented] (ACCUMULO-4540) '_devtools/git-hooks/post-commit' does not fail gracefully on missing the local branch 'asf-site'
Date Tue, 20 Dec 2016 22:01:58 GMT


Christopher Tubbs commented on ACCUMULO-4540:

This is just one of many possible error conditions. Presumably, the developer is already aware
of what a successful execution of the post-commit hook does, as well as its prerequisites...
they were the ones who copied (or symlink'd) it, after all. It could get quite tedious to
try to add verbose error messages on each possible error condition.

How about: "fatal: asf-site is not a branch; this script can only update branches named asf-site
(try: git checkout -t origin/asf-site)" ?

I think this is too long for an error message, but I think it covers all the bases. But, it's
not quite accurate enough... checking out the asf-site branch isn't good enough. You have
to re-run the script manually after doing that. We also can't assume they're using this script
as a post-commit hook. It works just as well with a manual execution, and the message shouldn't
be tailored towards the post-commit hook case, excluding others.

> '_devtools/git-hooks/post-commit' does not fail gracefully on missing the local branch
> -------------------------------------------------------------------------------------------------
>                 Key: ACCUMULO-4540
>                 URL:
>             Project: Accumulo
>          Issue Type: Bug
>          Components: website
>            Reporter: Josh Elser
>            Assignee: Christopher Tubbs
>            Priority: Trivial
> I did a fresh clone of the accumulo-website.git repository and copied the post-commit
hook into {{.git/hooks}}. Upon making my first commit, it failed:
> {{fatal: asf-site is not a branch}}
> Would be nice if we caught it when asf-site doesn't exist locally and give a better error

This message was sent by Atlassian JIRA

View raw message