changeset 3253:1e2941fda520

patchbomb: update --attach to use cmdutil.make_filename
author Brendan Cully <brendan@kublai.com>
date Wed, 04 Oct 2006 12:39:51 -0700
parents 27139167e615
children 168485fa44ba
files hgext/patchbomb.py
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/patchbomb.py	Wed Oct 04 11:14:33 2006 -0700
+++ b/hgext/patchbomb.py	Wed Oct 04 12:39:51 2006 -0700
@@ -65,7 +65,7 @@
 
 from mercurial.demandload import *
 demandload(globals(), '''email.MIMEMultipart email.MIMEText email.Utils
-                         mercurial:commands,hg,mail,ui,patch
+                         mercurial:cmdutil,commands,hg,mail,ui,patch
                          os errno popen2 socket sys tempfile time''')
 from mercurial.i18n import gettext as _
 from mercurial.node import *
@@ -146,10 +146,10 @@
             if patchname:
                 patchname = patchname[0]
             elif total > 1:
-                patchname = commands.make_filename(repo, '%b-%n.patch',
+                patchname = cmdutil.make_filename(repo, '%b-%n.patch',
                                                    binnode, idx, total)
             else:
-                patchname = commands.make_filename(repo, '%b.patch', binnode)
+                patchname = cmdutil.make_filename(repo, '%b.patch', binnode)
             p['Content-Disposition'] = 'inline; filename=' + patchname
             msg.attach(p)
         else: