Page MenuHomePhabricator

listpages.py: Add option for adding custom text before the list
Open, LowPublicFeature

Description

I have idea that we should add option for adding custom text before the list. It will be good so users can know what is list about.

Example:

In this list are articles with ref tags but have {{unreferenced}}.

* Article1
* Article2
* Article3

Event Timeline

Kizule created this task.Feb 29 2020, 9:00 PM
Kizule changed the subtype of this task from "Task" to "Feature Request".Feb 29 2020, 9:00 PM
This comment was removed by Dvorapa.
Xqt triaged this task as Low priority.Mar 2 2020, 11:10 AM

@Dvorapa I've a couple of getting started questions related to this task. Should the code changes take place in the script file core/scripts/listpages.py in https://gerrit.wikimedia.org/r/#/admin/projects/pywikibot/core? Should the main() function be expanded to handle an additional argument related to custom text? Please share any other tips for getting started on this task.

Both yes and yes! The script provides many parameters, so inspired by those adding another one should be an easy step. A newcomer then have to find a place where adding the prologue would be appropriate.

Xqt added a subscriber: Xqt.Apr 22 2020, 7:09 AM

I have idea that we should add option for adding custom text before the list. It will be good so users can know what is list about.

I think we can have both, text before and text after the list probably with options -pre and -post or something like that.

Change 611929 had a related patch set uploaded (by Shreyasminocha; owner: Shreyasminocha):
[pywikibot/core@master] Allow defining custom prefix/suffix in listpages

https://gerrit.wikimedia.org/r/611929

Xqt removed Shreyasminocha as the assignee of this task.Oct 23 2020, 11:09 AM
Xqt removed a project: Patch-Needs-Improvement.
Xqt added a subscriber: Shreyasminocha.

Change 611929 abandoned by Xqt:
[pywikibot/core@master] Allow defining custom prefix/suffix in listpages

Reason:
not an appropriate implementation

https://gerrit.wikimedia.org/r/611929

I would like to tackle this task if it's still active and would like to know what exactly should be done here. Thanks for the help!

@Xqt What should be done here? Thanks a lot for helping! :D

@Xqt Need help in getting started with this!