Skip to content

hackhitchin/mediawiki-extension-inventory

Repository files navigation

Hichin Hackspace Inventory Plugin

Status License: GPL v2 Build

A MediaWiki plugin developed by Hitchin Hackspace to track the location of our tools and consumables.

Development

First set up a local copy of MediaWiki by following the Developer Guide. You will also need node + npm.

Install a skin following the Skin configuration guide.

Clone this repo and install dependencies:

git clone [email protected]:hackhitchin/mediawiki-extension-inventory.git extentions/HackHitchinInventory
cd extensions/HackHitchinInventory
npm install
docker-compose exec -w /var/www/html/w/extensions/HackHitchinInventory mediawiki composer install

Add the following to the bottom of LocalSettings.php:

wfLoadExtension( "HackHitchinInventory");
$wgHackHitchinInventoryVandalizeEachPage = true;

Run the database patches:

docker-compose exec -w /var/www/html/w/extensions/HackHitchinInventory mediawiki composer update-db

Running tests:

docker-compose exec -w /var/www/html/w/extensions/HackHitchinInventory mediawiki composer test
npm test

Other options

  • Run composer locally instead of inside docker.
  • Run mediawiki on a local server instead of docker.

Database

Database schemas use the new abstract schema changes available from Mediawiki. The JSON files are stored in ./abstractSchemaChanges/ and the generated SQL is stored in ./sql/ the default is for MySQL, other databases are stored in named folders.

To generate SQL:

docker-compose exec -w /var/www/html/w/extensions/HackHitchinInventory mediawiki composer generate-sql

To apply changes:

docker-compose exec -w /var/www/html/w/extensions/HackHitchinInventory mediawiki composer update-db

To document

About

mediawiki-extension-inventory

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published