XZise added a subscriber: XZise. XZise added a comment.
Okay maybe this could be solved similar to https://gerrit.wikimedia.org/r/#/c/201446/1 . The script just defines a class or so which takes some keyword arguments. Each Wiki has then a `MediaWiki:FOO.js` JSON content (where FOO could be defined by the script or maybe `pywikibot-<scriptname>`). It then loads the JSON content and calls whatever is there to initialize the settings. So in the case of my patch the page would contain then on the English Wikipedia:
{ "name": "Orphan", "aliases": ["wi"], "parameters": "date={{subst:CURRENTMONTHNAME}} {{subst:CURRENTYEAR}}" }
And it would do then something like that in the script:
settings_page = 'pywikibot-lonelypages' pywikibot.bot.load_settings(settings_page, OrphanTemplate)
And then in the library we have a function which does some magic:
def load_settings(page_title, callback, site=None): site = site or pywikibot.Site() page = pywikibot.Page(site, page_title + '.js', 12) if page.exists(): return callback(**json.loads(page.get())) else: return False
TASK DETAIL https://phabricator.wikimedia.org/T94679
REPLY HANDLER ACTIONS Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: XZise Cc: XZise, jayvdb, Aklapper, pywikipedia-bugs