Make kwdemo more translation friendly
authorChristian Ebert <blacktrash@gmx.net>
Thu, 25 Jun 2009 11:58:30 +0200
changeset 590 527257649f20
parent 588 ed69ef4bd191
child 591 3b4d5045a920
child 592 ee684f9da112
Make kwdemo more translation friendly
hgkw/keyword.py
--- a/hgkw/keyword.py	Wed Jun 24 14:27:27 2009 +0200
+++ b/hgkw/keyword.py	Thu Jun 25 11:58:30 2009 +0200
@@ -281,9 +281,6 @@
 
     Override current keyword template maps with "default" option.
     '''
-    def demostatus(stat):
-        ui.status(_('\n\t%s\n') % stat)
-
     def demoitems(section, items):
         ui.write('[%s]\n' % section)
         for k, v in items:
@@ -323,7 +320,7 @@
         if k.endswith('keyword'):
             extension = '%s = %s' % (k, v)
             break
-    demostatus('config using %s keyword template maps' % kwstatus)
+    ui.status(_('\n\tconfig using %s keyword template maps\n') % kwstatus)
     ui.write('[extensions]\n%s\n' % extension)
     demoitems('keyword', ui.configitems('keyword'))
     demoitems('keywordmaps', kwmaps.iteritems())
@@ -346,7 +343,7 @@
     ui.note('hg -R "%s" ci -m "%s"\n' % (tmpdir, msg))
     repo.commit(text=msg)
     fmt = ui.verbose and ' in %s' % path or ''
-    demostatus('%s keywords expanded%s' % (kwstatus, fmt))
+    ui.status(_('\n\t%s keywords expanded%s\n') % (kwstatus, fmt))
     ui.write(repo.wread(fn))
     ui.debug(_('\nremoving temporary repository %s\n') % tmpdir)
     shutil.rmtree(tmpdir, ignore_errors=True)