[PATCH 2 of 2 stable] keyword: go into restricted mode when transplanting

Christian Ebert blacktrash at gmx.net
Tue Dec 22 16:55:33 CST 2009


# HG changeset patch
# User Christian Ebert <blacktrash at gmx.net>
# Date 1261522139 0
# Node ID a00a959e232f1f6d60353b7d5b2b3088d97294bf
# Parent  bc047172eaa7db410be9e02737619e79453fa4a3
keyword: go into restricted mode when transplanting

Expanded keyword is read into diff with transplant -b otherwise.

Thanks to Adam Berkes for providing an example case.

diff --git a/hgext/keyword.py b/hgext/keyword.py
--- a/hgext/keyword.py
+++ b/hgext/keyword.py
@@ -93,7 +93,8 @@
 
 # hg commands that trigger expansion only when writing to working dir,
 # not when reading filelog, and unexpand when reading from working dir
-restricted = 'merge record resolve qfold qimport qnew qpush qrefresh qrecord'
+restricted = ('merge record resolve qfold qimport qnew qpush qrefresh qrecord'
+              ' transplant')
 
 # provide cvs-like UTC date filter
 utcdate = lambda x: util.datestr(x, '%Y/%m/%d %H:%M:%S')


More information about the Mercurial-devel mailing list