http://www.mediawiki.org/wiki/Special:Code/pywikipedia/10193
Revision: 10193 Author: xqt Date: 2012-05-06 06:23:41 +0000 (Sun, 06 May 2012) Log Message: ----------- i18n.input() from trunk
Modified Paths: -------------- branches/rewrite/scripts/redirect.py
Modified: branches/rewrite/scripts/redirect.py =================================================================== --- branches/rewrite/scripts/redirect.py 2012-05-06 06:22:31 UTC (rev 10192) +++ branches/rewrite/scripts/redirect.py 2012-05-06 06:23:41 UTC (rev 10193) @@ -50,7 +50,7 @@ # (C) Daniel Herding, 2004. # (C) Purodha Blissenbach, 2009. # (C) xqt, 2009-2012 -# (C) Pywikipedia bot team, 2004-2011 +# (C) Pywikipedia bot team, 2004-2012 # # Distributed under the terms of the MIT license. # @@ -667,8 +667,7 @@ action = 'both' elif arg.startswith('-xml'): if len(arg) == 4: - xmlFilename = pywikibot.input( - u'Please enter the XML dump's filename: ') + xmlFilename = i18n.input('pywikibot-enter-xml-filename') else: xmlFilename = arg[5:] elif arg.startswith('-moves'): @@ -677,10 +676,8 @@ ns = arg[11:] if ns == '': ## "-namespace:" does NOT yield -namespace:0 further down the road! - ns = pywikibot.input( - u'Please enter a namespace by its number: ') -# u'Please enter a namespace by its name or number: ') -# TODO! at least for some generators. + ns = i18n.input('pywikibot-enter-namespace-number') +# TODO! at least for some generators enter a namespace by its name or number if ns == '': ns = '0' try:
pywikipedia-svn@lists.wikimedia.org