Extension:BugSquish

Note - the most up to date version of this documentation is available at http://www.kennel17.co.uk/testwiki/BugSquish. -

This extension checks your Bugzilla installation and adds a strikethrough to interwiki links for closed bugs.

Installation
Simply copy and paste the code (below) into a new file in your 'extensions' directory and include it from your LocalSettings.php file in the usual way.

Requirements
Firstly, links to your Bugzilla installation need to be setup in your interwiki table. For example you might setup an interwiki link called  with the URL. This means you can enter the wiki code  to create a link to bug 2314 in your Bugzilla install (resulting in a link such as: bug:2314).

For BugSquish to work are you need to have an interwiki prefix that accepts just a single number, and that the DB containing the bugs must be accessible locally (though the code is designed to allow for alternative access to the Bugzilla data (e.g. via WebDAV)... so long as someone fills in the necessary code!).

Multiple interwiki prefixes to different Bugzillas can be defined, but currently the code only works with Bugzilla installations - no other bugtrack systems are currently supported.

Configuration
For each interwiki link that you want to use, you need to add an entry into. Each entry has the following required elements:


 * interwiki => The interwiki prefix this definition applies to.
 * type => The type of connection. Currently only   is valid for this field.

The following elements are only required if necessary:
 * prefix => DB prefix (as setup in your Bugzilla installation - can be omitted if no prefix used).

The following optional elements can be used to define the database connection. If any of the elements are omitted, then the values used for your MediaWiki installation are used. Therefore if Bugzilla shares a database with MediaWiki (and the MediaWiki user has appropriate access privileges) then you can omit all of the settings. If not, then fill in anything that differs from your MediaWiki install.
 * host => The database host.
 * database => The database name.
 * user => Username for DB connection.
 * password => Password for DB connection.

Example 1 - shared DB
If MediaWiki and Bugzilla are installed in a single DB, then you only need to specify a minimal set of components:

Example 1 - separate DB
If Bugzilla is stored in a separate DB, then you need to supply details. In most cases 'host' will be the same as for MediaWiki, in which case it can be omitted (as it has been here). Also if no table prefix is used in your Bugzilla install, then that field can be omitted.

Source Code
Available from http://www.kennel17.co.uk/testwiki/BugSquish.