Do not shadow builtin format (detected by pychecker)
authorChristian Ebert <blacktrash@gmx.net>
Tue, 25 Nov 2008 18:13:05 +0100
changeset 509 16b690351c0d
parent 507 51296bd1652f
child 510 ee27d91bacae
child 516 0107b6de1a35
Do not shadow builtin format (detected by pychecker)
hgkw/keyword.py
--- a/hgkw/keyword.py	Fri Nov 14 22:29:03 2008 +0100
+++ b/hgkw/keyword.py	Tue Nov 25 18:13:05 2008 +0100
@@ -350,8 +350,8 @@
     ui.note(_('unhooked all commit hooks\n'))
     ui.note('hg -R "%s" ci -m "%s"\n' % (tmpdir, msg))
     repo.commit(text=msg)
-    format = ui.verbose and ' in %s' % path or ''
-    demostatus('%s keywords expanded%s' % (kwstatus, format))
+    fmt = ui.verbose and ' in %s' % path or ''
+    demostatus('%s keywords expanded%s' % (kwstatus, fmt))
     ui.write(repo.wread(fn))
     ui.debug(_('\nremoving temporary repo %s\n') % tmpdir)
     shutil.rmtree(tmpdir, ignore_errors=True)
@@ -384,9 +384,9 @@
     if opts.get('all') or opts.get('ignore'):
         kwfstats += (('I', [f for f in files if f not in kwfiles]),)
     for char, filenames in kwfstats:
-        format = (opts.get('all') or ui.verbose) and '%s %%s\n' % char or '%s\n'
+        fmt = (opts.get('all') or ui.verbose) and '%s %%s\n' % char or '%s\n'
         for f in filenames:
-            ui.write(format % repo.pathto(f, cwd))
+            ui.write(fmt % repo.pathto(f, cwd))
 
 def shrink(ui, repo, *pats, **opts):
     '''revert expanded keywords in working directory