[PATCH] color: add support for record extension

TK Soh teekaysoh at gmail.com
Thu Oct 8 01:58:50 UTC 2009


# HG changeset patch
# User TK Soh <teekaysoh at gmail.com>
# Date 1254965242 -28800
# Node ID 53e49cdf9727d072a2f3bae86774700f3259820d
# Parent  d932dc6558812678bb374d66a364212d54503744
color: add support for record extension

diff --git a/hgext/color.py b/hgext/color.py
--- a/hgext/color.py
+++ b/hgext/color.py
@@ -234,6 +234,13 @@
         # The mq extension is not enabled
         pass

+    try:
+        rec = extensions.find('record')
+        _setupcmd(ui, 'record', rec.cmdtable, colordiff, _diff_effects)
+    except KeyError:
+        # The record extension is not enabled
+        pass
+
 def _setupcmd(ui, cmd, table, func, effectsmap):
     '''patch in command to command table and load effect map'''
     def nocolor(orig, *args, **opts):



More information about the Mercurial-devel mailing list