def _raiseExceptionIfHookFailed(file_, exitStatus):
    """
    Will raise an exception with the hook file and the exit status in the
    error message if the exit status is not zero.
    """
    if exitStatus is not 0:
        raise Exception('Hook {0} failed with status {1}'.format(file_, int
            (exitStatus / 256)))
