[PATCH 4 of 4] keyword: support qrecord
Christian Ebert
blacktrash at gmx.net
Wed Apr 21 03:17:34 CDT 2010
# HG changeset patch
# User Christian Ebert <blacktrash at gmx.net>
# Date 1271837829 -7200
# Node ID ec390b61a71de180f96ad647338d050859983000
# Parent 457e04aac08e41bb465ffd11b10fe2260e2e42b0
keyword: support qrecord
diff --git a/hgext/keyword.py b/hgext/keyword.py
--- a/hgext/keyword.py
+++ b/hgext/keyword.py
@@ -89,6 +89,8 @@
# not when reading filelog, and unexpand when reading from working dir
restricted = 'merge record qrecord resolve transplant'
+recordcommands = 'record qrecord'
+
# provide cvs-like UTC date filter
utcdate = lambda x: util.datestr((x[0], 0), '%Y/%m/%d %H:%M:%S')
@@ -485,7 +487,7 @@
n = super(kwrepo, self).commitctx(ctx, error)
# no lock needed, only called from repo.commit() which already locks
# prevent keyword expansion within record's internal commitfunc
- if kwtools['hgcmd'] != 'record':
+ if kwtools['hgcmd'] not in recordcommands.split():
kwt.overwrite(n, True, None)
return n
More information about the Mercurial-devel
mailing list