jayvdb added a comment.
Note handleArgs has been replaced with handle_args.
! In T70664#739409, @zhuyifei1999 wrote:
--help or -h would do:
$ python pwb.py scripts/replicate_wiki.py -h usage: replicate_wiki.py [-h] [-f FAMILY] [-r] [-o ORIGINAL_WIKI] [-ns NAMESPACE] [-dns DEST_NAMESPACE] destination [destination ...]
positional arguments: destination destination wiki(s)
optional arguments: -h, --help show this help message and exit -f FAMILY, --family FAMILY wiki family -r, --replace actually replace pages (without this option you will only get an overview page) -o ORIGINAL_WIKI, --original ORIGINAL_WIKI original wiki -ns NAMESPACE, --namespace NAMESPACE specify namespace -dns DEST_NAMESPACE, --dest-namespace DEST_NAMESPACE destination namespace (if different)
--help does emi the above, bit --help/-help should also show the global options which are documented in pywikibot/bot.py showHelp() variable globalHelp
this is tested by tests/script_tests.py - edit that file to see replicate_wiki.py is treated differently because it doesnt emit the standard global help message.
TASK DETAIL https://phabricator.wikimedia.org/T70664
REPLY HANDLER ACTIONS Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
To: jayvdb Cc: pywikipedia-bugs, zhuyifei1999, Ricordisamoa, jayvdb