mercurial/commands.py
changeset 335 74b9332faece
parent 333 d60a3060f9e2
child 338 1e091b3293d5
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -627,7 +627,7 @@ norepo = "init branch help debugindex de
 def find(cmd):
     i = None
     for e in table.keys():
-        if re.match(e + "$", cmd):
+        if re.match("(%s)$" % e, cmd):
             return table[e]
 
     raise UnknownCommand(cmd)