Mercurial > public > mercurial-scm > hg
comparison mercurial/ui.py @ 26235:6c962145f523
ui: improve docs on ui.log
This makes the documentation on ui.log line up with the use of that
interface in blackbox.
author | Augie Fackler <augie@google.com> |
---|---|
date | Thu, 10 Sep 2015 10:50:03 -0400 |
parents | 663fbc336e22 |
children | 60558319ce72 |
comparison
equal
deleted
inserted
replaced
26234:e4609ec959f8 | 26235:6c962145f523 |
---|---|
967 def log(self, service, *msg, **opts): | 967 def log(self, service, *msg, **opts): |
968 '''hook for logging facility extensions | 968 '''hook for logging facility extensions |
969 | 969 |
970 service should be a readily-identifiable subsystem, which will | 970 service should be a readily-identifiable subsystem, which will |
971 allow filtering. | 971 allow filtering. |
972 message should be a newline-terminated string to log. | 972 |
973 ''' | 973 *msg should be a newline-terminated format string to log, and |
974 pass | 974 then any values to %-format into that format string. |
975 | |
976 **opts currently has no defined meanings. | |
977 ''' | |
975 | 978 |
976 def label(self, msg, label): | 979 def label(self, msg, label): |
977 '''style msg based on supplied label | 980 '''style msg based on supplied label |
978 | 981 |
979 Like ui.write(), this just returns msg unchanged, but extensions | 982 Like ui.write(), this just returns msg unchanged, but extensions |