diff hgext/color.py @ 25510:dd511b5cb818

color: copy docstring of label() template function to wrapper Otherwise label() wouldn't be listed in "hg help template" if color extension is enabled.
author Yuya Nishihara <yuya@tcha.org>
date Wed, 10 Jun 2015 22:08:15 +0900
parents ceec79b5657a
children fd5bc660c9f0
line wrap: on
line diff
--- a/hgext/color.py	Mon Jun 08 18:48:45 2015 +0900
+++ b/hgext/color.py	Wed Jun 10 22:08:15 2015 +0900
@@ -531,6 +531,7 @@
         return orig(gitsub, commands, env, stream, cwd)
     extensions.wrapfunction(dispatch, '_runcommand', colorcmd)
     extensions.wrapfunction(subrepo.gitsubrepo, '_gitnodir', colorgit)
+    templatelabel.__doc__ = templater.funcs['label'].__doc__
     templater.funcs['label'] = templatelabel
 
 def extsetup(ui):