Mercurial > kallithea
diff rhodecode/lib/middleware/simplegit.py @ 2969:5085e51fba3a beta
Implemented #628: Pass server URL to rc-extensions hooks
- updated rc-ext docs
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Sat, 27 Oct 2012 15:36:53 +0200 |
parents | ccbdff90e5a0 |
children | a5f0bc867edc 9b92cf5a0cca |
line wrap: on
line diff
--- a/rhodecode/lib/middleware/simplegit.py Sat Oct 27 15:07:01 2012 +0200 +++ b/rhodecode/lib/middleware/simplegit.py Sat Oct 27 15:36:53 2012 +0200 @@ -79,7 +79,7 @@ from webob.exc import HTTPNotFound, HTTPForbidden, HTTPInternalServerError, \ HTTPBadRequest, HTTPNotAcceptable -from rhodecode.lib.utils2 import safe_str, fix_PATH +from rhodecode.lib.utils2 import safe_str, fix_PATH, get_server_url from rhodecode.lib.base import BaseVCSController from rhodecode.lib.auth import get_container_username from rhodecode.lib.utils import is_valid_repo, make_ui @@ -189,6 +189,7 @@ # extras are injected into UI object and later available # in hooks executed by rhodecode from rhodecode import CONFIG + server_url = get_server_url(environ) extras = { 'ip': ipaddr, 'username': username, @@ -196,6 +197,7 @@ 'repository': repo_name, 'scm': 'git', 'config': CONFIG['__file__'], + 'server_url': server_url, 'make_lock': None, 'locked_by': [None, None] }