--- a/hgext/color.py Wed Mar 02 15:50:34 2016 +0000
+++ b/hgext/color.py Thu Jun 11 22:58:27 2015 +0900
@@ -485,10 +485,6 @@
# i18n: "label" is a keyword
raise error.ParseError(_("label expects two arguments"))
- # add known effects to the mapping so symbols like 'red', 'bold',
- # etc. don't need to be quoted
- mapping.update(dict([(k, k) for k in _effects]))
-
thing = templater.evalstring(context, mapping, args[1])
# apparently, repo could be a string that is the favicon?
@@ -496,7 +492,9 @@
if isinstance(repo, str):
return thing
- label = templater.evalstring(context, mapping, args[0])
+ # preserve unknown symbol as literal so effects like 'red', 'bold',
+ # etc. don't need to be quoted
+ label = templater.evalstringliteral(context, mapping, args[0])
return repo.ui.label(thing, label)