Mercurial > kallithea
comparison rhodecode/model/repo.py @ 2407:8a68e0292232 beta
Change git & hg hooks to post. They shouldn't block as they are used just for logging actions. Futhermore post hooks have access to changesets, so it's much better flexible
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Wed, 06 Jun 2012 22:23:27 +0200 |
parents | a3efdd61a21f |
children | d3978233fcfa |
comparison
equal
deleted
inserted
replaced
2406:7be31af5bc78 | 2407:8a68e0292232 |
---|---|
474 os.makedirs(loc) | 474 os.makedirs(loc) |
475 | 475 |
476 tmpl = pkg_resources.resource_string( | 476 tmpl = pkg_resources.resource_string( |
477 'rhodecode', jn('config', 'pre_receive_tmpl.py') | 477 'rhodecode', jn('config', 'pre_receive_tmpl.py') |
478 ) | 478 ) |
479 _hook_file = jn(loc, 'pre-receive') | 479 _hook_file = jn(loc, 'post-receive') |
480 with open(_hook_file, 'wb') as f: | 480 with open(_hook_file, 'wb') as f: |
481 f.write(tmpl) | 481 f.write(tmpl) |
482 os.chmod(_hook_file, 0555) | 482 os.chmod(_hook_file, 0555) |
483 | 483 |
484 else: | 484 else: |