[Tutor] nose, git, post-commit hook

Albert-Jan Roskam fomcl at yahoo.com
Tue Feb 5 13:01:02 CET 2013



> On 4 February 2013 15:32, Albert-Jan Roskam <fomcl at yahoo.com> wrote:
>> I am using git VCS and I read about the possibility to use post-commit 
> hooks for nose tests. That sounds pretty cool, but does this also have 
> disadvantages?
>> It would be very annoying if I couldn't check in code, safely tucked 
> away on some server, that is not yet working. Is there also a way to by-pass the 
> 'mandatory' tests?
> 
> This isn't really a Python question, but if you use pre-commit hooks,
> you can bypass them with the "--no-verify" option to "git 
> commit". See
> http://git-scm.com/book/en/Customizing-Git-Git-Hooks.

Hi Rob,

Thanks for this useful link. I'll see what's most practical for me. As usual, the number of options of git is bedazzlingly large.
I dared to ask this question on the Python list because I am planning to use this in conjunction with the nose package.
I figured that this package (or something of python) *may* have some other functionality that ensures that tests are automatically 
run on a regular basis. It would be ideal if it could be combined with other tasks (I have pylint or pep8 in mind). Commit hooks appear
to be a good method.

Regards,
Albert-Jan


More information about the Tutor mailing list