[Mediawiki-l] Gadget copy script
billinghurst at gmail.com
Wed Mar 21 03:34:45 UTC 2012
Why are we importing gadgets to new sites, I thought that the whole
purpose of ResourceLoader was to stop the proliferation of gadgets and
especially versions of gadgets. In fact we have been trying to look to
standardise and align the gadgets to a master copy in a number of places.
On Tue, 20 Mar 2012 22:15:05 -0400, mah at wikimedia.org (Mark A.
> In the past few months, I've needed to test gadgets that are used on WMF
> sites, but didn't have an easy way to copy them from, say, Commons to
> Beta in Labs.
> I hacked something together and then forgot about it until Chris McMahon
> (the WMF's new QA guy) wanted something similar for one of his test
> wikis a couple of weeks ago. I couldn't find it, so last night I
> rewrote the script from scratch.
> The script is pretty ugly and, normally, I might commit it to SVN and
> work on it there, but we're in the process of moving to Git, so I've
> gone ahead and created a gitorious repository:
> Lots of hard-coding that could be cleaned up, and it could use the API
> to copy from one wiki to another, but its a start. I'm sharing it here
> so that other people can begin to use it.
> It just blats the import-able file out on standard output for now, and
> it only copies from Commons, so it should be used in the following way:
> $ php dupe-gadgets.php > import-this-file.xml
> [ Go to Special:Import on your wiki and import. ]
> I hope that it helps someone!
More information about the MediaWiki-l