[Mediawiki-l] New importImages.php - what to do with it?

Emanuele D'Arrigo manu3d at gmail.com
Wed Aug 1 21:25:24 UTC 2007


Hi everybody,

I just finished hacking the mantainance/importImages.php script,
and it can now handle (seemingly safely) pre-existing files.

Removing the existence check as I suggested in a previous
email was working, but it was fairly unsafe: the file was overwritten
and no archive version was created. This resulted in the impossibility
to view, delete or revert to earlier version - not quite ideal.

I seem to have been able to fix those problems and it appears
to be doing the right thing, plus I've added a feature that
a) creates two "accepted" and "rejected" directories
b) moves the original files in one of those directories
depending if it has been successfully uploaded or not.

The latter feature is useful for a scheduled import, so
that as the script gets called every 15 minutes or so,
it doesn't upload images that had been uploaded 15
minutes earlier and haven't been manually removed
from the source directory.

The question is, if I want to make it publicly available
(I have to ask permissions to the company first), what's
the best way to do so? And how do I get it double
checked - testing and code?

Thanks for your help!

Manu


More information about the MediaWiki-l mailing list