jirikuncar/invenio-kwalitee — pull request #39 by lnielsen-cern (2014-07-22 10:41:13+00:00)
Title: hooks: exit code fix

Fixes problem with hooks exit code, that prevented hooks from aborting the commit.

Hook functions would return ``False`` on failures, and ``None`` on success which would be passed to ``sys.exit()``. Both however result in exit code 0:

```console
$ python -c "import sys;sys.exit(None)" ; echo $?
0
$ python -c "import sys;sys.exit(False)" ; echo $?
0
```

Thus hook functions now return an integer (0 or 1).