jenkins-bot has submitted this change and it was merged.
Change subject: listpages: report number of pages found ......................................................................
listpages: report number of pages found
Bug: T93474 Change-Id: If80c25d3b69a2786d29d5dc4bf21783cd22d9e35 --- M scripts/listpages.py 1 file changed, 2 insertions(+), 0 deletions(-)
Approvals: XZise: Looks good to me, approved jenkins-bot: Verified
diff --git a/scripts/listpages.py b/scripts/listpages.py index 72cfcb5..55da78b 100644 --- a/scripts/listpages.py +++ b/scripts/listpages.py @@ -213,6 +213,7 @@
gen = genFactory.getCombinedGenerator() if gen: + i = 0 for i, page in enumerate(gen, start=1): if not notitle: page_fmt = Formatter(page, outputlang) @@ -227,6 +228,7 @@ pywikibot.output(u'Saving %s to %s' % (page.title(), filename)) with open(filename, mode='wb') as f: f.write(page.text.encode(encoding)) + pywikibot.output(u"%i page(s) found" % i) else: pywikibot.showHelp()
pywikibot-commits@lists.wikimedia.org