[PATCH 5 of 5 V2] templater: add an alias called 'color' for 'label'

Sean Farley sean.michael.farley at gmail.com
Mon Apr 7 16:17:04 CDT 2014


# HG changeset patch
# User Sean Farley <sean.michael.farley at gmail.com>
# Date 1396903127 18000
#      Mon Apr 07 15:38:47 2014 -0500
# Node ID de61eae794304fcdeef700f0e6f995684795d808
# Parent  9211c7e2e984bbc0b4366d2d2ed8c312c0b949a1
templater: add an alias called 'color' for 'label'

diff --git a/hgext/color.py b/hgext/color.py
--- a/hgext/color.py
+++ b/hgext/color.py
@@ -422,10 +422,11 @@ def uisetup(ui):
             extstyles()
             configstyles(ui_)
         return orig(ui_, opts, cmd, cmdfunc)
     extensions.wrapfunction(dispatch, '_runcommand', colorcmd)
     templater.funcs['label'] = templatelabel
+    templater.funcs['color'] = templatelabel
 
 def extsetup(ui):
     commands.globalopts.append(
         ('', 'color', 'auto',
          # i18n: 'always', 'auto', and 'never' are keywords and should


More information about the Mercurial-devel mailing list