equal
deleted
inserted
replaced
187 _redirect = False |
187 _redirect = False |
188 def redirect(state): |
188 def redirect(state): |
189 global _redirect |
189 global _redirect |
190 _redirect = state |
190 _redirect = state |
191 |
191 |
|
192 def hashook(ui, htype): |
|
193 """return True if a hook is configured for 'htype'""" |
|
194 if not ui.callhooks: |
|
195 return False |
|
196 for hname, cmd in _allhooks(ui): |
|
197 if hname.split('.')[0] == htype and cmd: |
|
198 return True |
|
199 return False |
|
200 |
192 def hook(ui, repo, htype, throw=False, **args): |
201 def hook(ui, repo, htype, throw=False, **args): |
193 if not ui.callhooks: |
202 if not ui.callhooks: |
194 return False |
203 return False |
195 |
204 |
196 hooks = [] |
205 hooks = [] |