diff hgext/evolve.py @ 915:1ebe5c51919b stable

fold: enable --date and --user options Like all other commit-creating commits, `hg fold` should also have these options enabled. This also allows getting consistent hashes during tests involving fold.
author Jordi Gutiérrez Hermoso <jordigh@octave.org>
date Fri, 11 Apr 2014 19:24:29 -0400
parents 0c1907a65b9f
children a94ce5400e1b ffce88754767
line wrap: on
line diff
--- a/hgext/evolve.py	Wed Apr 23 14:15:40 2014 -0700
+++ b/hgext/evolve.py	Fri Apr 11 19:24:29 2014 -0400
@@ -1728,7 +1728,7 @@
 
 @command('^fold',
     [('r', 'rev', [], _("explicitly specify the full set of revision to fold")),
-    ],
+    ] + commitopts2,
     # allow to choose the seed ?
     _('rev'))
 def fold(ui, repo, *revs, **opts):
@@ -1769,12 +1769,13 @@
         lock = repo.lock()
         tr = repo.transaction('touch')
         try:
+            commitopts = opts.copy()
             allctx = [repo[r] for r in revs]
             targetphase = max(c.phase() for c in allctx)
             msgs = ["HG: This is a fold of %d changesets." % len(allctx)]
             msgs += ["HG: Commit message of changeset %s.\n\n%s\n" %
                      (c.rev(), c.description()) for c in allctx]
-            commitopts = {'message': "\n".join(msgs)}
+            commitopts['message'] = "\n".join(msgs)
             commitopts['edit'] = True
             newid, _ = rewrite(repo, root, allctx, head,
                              [root.p1().node(), root.p2().node()],