Tool for cropping images at Wikimedia Commons and other Wikimedia wikis
OTHER License
CropTool is a tool for cropping image files at Wikimedia Commons and other Wikimedia sites using the MediaWiki API with OAuth.
Features:
?title=Example.jpg&left=10&top=10&width=150&height=100
?title=Example.jpg&left=10&top=10&right=10&bottom=10
{{Remove border}}
,{{Watermark}}
and{{Trimming}}
, and{{Extracted from}}
template is added to the new file, and the{{Image extracted}}
template is added or updated on the original.{{Flickrreview}}
User:FlickreviewR
subtemplates),{{Orphaned non-free revisions}}
Copy config.dev.ini
to config.ini
and add the consumer token and secret token to config.ini
and check the default paths for the dependencies.
docker compose run phpfpm composer install
npm install
npx gulp build
docker compose run phpfpm php generate-key.php
docker-compose up
Note that you should be able to login and preview cropping without waiting for the OAuth consumer to be accepted.
ssh tools-login.wmflabs.org
become croptool
git pull
toolforge build start https://github.com/danmichaelo/croptool.git
toolforge webservice --backend=kubernetes --mount=all buildservice restart
First-time setup:
config.prod.ini
into the home directory, and add OAuth informationpublic_files
directory in the home directory and set it to be readable and writable by others