jenkins-bot has submitted this change and it was merged.
Change subject: use i18n parameter for replacement of category title ......................................................................
use i18n parameter for replacement of category title
uses new i18n file comitted with https://gerrit.wikimedia.org/r/#/c/113374/
Change-Id: I298a7a3ae8037348f3888a7f06df893278bcfc71 --- M scripts/makecat.py 1 file changed, 4 insertions(+), 5 deletions(-)
Approvals: Merlijn van Deen: Looks good to me, approved jenkins-bot: Verified
diff --git a/scripts/makecat.py b/scripts/makecat.py index 509f8b9..4f34b6f 100644 --- a/scripts/makecat.py +++ b/scripts/makecat.py @@ -32,7 +32,7 @@ """
# (C) Andre Engels, 2004 -# (C) Pywikipedia bot team 2005-2010 +# (C) Pywikibot team 2005-2014 # # Distributed under the terms of the MIT license. # @@ -51,8 +51,7 @@
def isdate(s): - """returns true iff s is a date or year - """ + """returns true if s is a date or year """ dict, val = date.getAutoFormat(pywikibot.getSite().language(), s) return dict is not None
@@ -126,7 +125,7 @@ ctoshow = 500 pywikibot.output(u'') pywikibot.output(u"==%s==" % pl.title()) - while 1: + while True: answer = raw_input("y(es)/n(o)/i(gnore)/(o)ther options? ") if answer == 'y': include(pl) @@ -222,7 +221,7 @@ workingcatname = ' '.join(workingcatname) mysite = pywikibot.getSite() workingcatname = unicode(workingcatname, 'utf-8') - pywikibot.setAction(i18n.twtranslate(mysite, 'makecat-create') + u' ' + workingcatname) + pywikibot.setAction(i18n.twtranslate(mysite, 'makecat-create', {'cat': workingcatname)}) workingcat = pywikibot.Category(mysite, u'%s:%s' % (mysite.category_namespace(),
pywikibot-commits@lists.wikimedia.org