[PATCH] hook: give exthooks tags for blocking time

Simon Farnsworth simonfar at fb.com
Mon Mar 6 11:09:27 UTC 2017


# HG changeset patch
# User Simon Farnsworth <simonfar at fb.com>
# Date 1488798555 28800
#      Mon Mar 06 03:09:15 2017 -0800
# Node ID 9bdc781849eb9bba369cf9698cb8a1f5aef2b966
# Parent  b4cd912d7704cd976e1bee3a3c927e0e578ec88f
hook: give exthooks tags for blocking time

The ui.system autogenerated tag isn't really useful - as they're named, let's
use the name the user gave us.

diff --git a/mercurial/hook.py b/mercurial/hook.py
--- a/mercurial/hook.py
+++ b/mercurial/hook.py
@@ -142,7 +142,7 @@
         cwd = repo.root
     else:
         cwd = pycompat.getcwd()
-    r = ui.system(cmd, environ=env, cwd=cwd)
+    r = ui.system(cmd, environ=env, cwd=cwd, blockedtag='exthook-%s' % (name,))
 
     duration = util.timer() - starttime
     ui.log('exthook', 'exthook-%s: %s finished in %0.2f seconds\n',


More information about the Mercurial-devel mailing list